I needed a quick way to start a specific subversion line at boot time so i threw together this script.
I will probably go through it again and add the lines to stop the daemon…maybe
———————Start of Script—————————————
#!/bin/bash
#
# /etc/rc.d/init.d/extras
# extras This shell script takes care of starting and stopping
# The SVN daemon and restarting samba (needed for some reason)
# The samba line will be removed when the prob is fixed
#
#
#
start() {
echo -n “Starting SVN and restarting Samba: ”
svnserve -d -r /mnt/data/SVN/
/etc/init.d/samba restart
return
}
stop() {
echo -n “Shutting down Extra Scripts (This does Nothing): “
}
case “$1” in
start)
start
;;
stop)
stop
;;
restart)
stop
start
;;
*)
echo “Usage: {start|stop|restart}”
exit 1
;;
esac
exit $?
———————End of Script—————————————-
Dont forget yau will need to add execute permissions for it to actualy run