[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Automatically restart daemons

>>>>> "Matt" == Matt Kern <mwk20@cam.ac.uk> writes:

    Matt> It might be a nice idea if we put the code to restart
    Matt> various daemons into their config files.

    Matt> e.g. # /etc/inetd.conf: see inetd(8) for further
    Matt> informations.
    Matt> 	#
    Matt> 	# Internet server configuration database
    Matt> 	...
    Matt> 	# Local variables: mode: text compile-command: "kill
    Matt> 	# -HUP `cat /var/run/inetd.pid`" End:

    Matt> This is a very useful feature and can really help the
    Matt> turnaround time for adding new services manually.  Any
    Matt> thoughts?

 I wrote an XEmacs/Emacs extension called `after-save-commands.el'
 that lets you set up a command to be run after saving a file...  It
 installs a find-file-hook that watches for files with names matching
 the ones you've configured via a `customize-variable' interface, and
 when it finds one, it installs a buffer-local `after-save-hook' that
 will run your configured shell command after saving the file.  It's
 great for running `newaliases', or reloading a daemon after you edit
 its configuration files.

 You can find a copy either bundled with recent versions of XEmacs, or 
 at <URL:http://master.debian.org/~karlheg/XE-Lisp/>.  I think it will 
 work in GNU Emacs also; YMMV.

Reply to: