#!/sbin/sh # # /etc/init.d/p4d-watch.d - start/stop p4d-watch and p4d-watch-admin # # Add a link to this script in /etc/rc3.d # # Note: Does not attempt to determine --change for missed events between a stop and start # Could catch the kill signal and write out the changelist number # # $Id: //guest/brad_barber/p4d-watch/main/p4d-watch.d#3 $ # $Date: 2002/07/09 $$Change: 1940 $$Author: brad_barber $ # case $1 in 'start') su - releng -c 'cd /var/perforce; /road/perforce/triggers/p4d-watch.pl --follow&' su - releng -c 'cd /var/perforce; /road/perforce/triggers/p4d-watch-admin.pl --follow&' ;; 'stop') su - releng -c 'pkill -u releng p4d-watch' ;; *) echo "usage: $0 {start|stop}" ;; esac