#!/bin/zsh
############################################################## {{{1 ##########
#   $Author: krischik@macports.org $
#   $Revision: 61574 $
#   $Date: 2009-12-15 10:37:55 +0000 (Tue, 15 Dec 2009) $
#   $HeadURL: branches/mld-qt-481/dports/news/leafnode/files/Restart_Texpire.command.in $
############################################################## }}}1 ##########

setopt X_Trace;

if test "${USER}" = "root"; then
    if test ! -L /Library/LaunchDaemons/org.macports.texpire.plist; then
	ln -s										    \
	    @PREFIX@/etc/LaunchDaemons/org.macports.leafnode/org.macports.texpire.plist	    \
	    /Library/LaunchDaemons/org.macports.texpire.plist				    ;
    fi;

    launchctl unload -w	/Library/LaunchDaemons/org.macports.texpire.plist
    launchctl load   -w	/Library/LaunchDaemons/org.macports.texpire.plist
else
    sudo ${0};
fi;

############################################################ {{{1 ###########
# vim: set nowrap tabstop=8 shiftwidth=4 softtabstop=4 noexpandtab :
# vim: set textwidth=0 filetype=zsh foldmethod=marker nospell :
