Skip to Main Content
Linux Desktop Hacks
book

Linux Desktop Hacks

by Nicholas Petreley, Jono Bacon
March 2005
Beginner to intermediate content levelBeginner to intermediate
342 pages
15h 55m
English
O'Reilly Media, Inc.
Content preview from Linux Desktop Hacks
Don’t Let Elvis Leave the Building #73
Chapter 9, Administration and Automation
|
225
HACK
HACK
#73
Don’t Let Elvis Leave the Building Hack #73
Keep a program running in the background by automatically restarting it
whenever it exits.
Some programs behave contrary to our wishes and exit prematurely, either
because they are designed to do so, or because they are flaky and prone to
crashing. This hack provides a neat trick to restart such programs automati-
cally every time they exit.
The xcompmgr program that provides drop shadows and other special
effects for Xorg is still a work in progress, and it often exits unexpectedly.
With a simple script, you can automatically restart it every time it exits.
First, log in as root, fire up your favorite editor, and create the following
script, naming it /usr/local/bin/keep-xcompmgr-running:
Figure 9-1. The Gnome Sessions settings dialog
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Linux Server Hacks, Volume Two

Linux Server Hacks, Volume Two

William von Hagen, Brian K. Jones
Introducing Linux Distros

Introducing Linux Distros

Jose Dieguez Castro

Publisher Resources

ISBN: 0596009119Supplemental ContentCatalog PageErrata