#! /bin/sh


EXEC=ups_shutdown

if [ "$1" == "x" ] ; then
chkconfig --del $EXEC
rm -f /etc/init.d/$EXEC
exit 
fi

EDIR=`pwd`


cp -f install.sh.src $EXEC.sh
sed -i "s|{EDIR}|$EDIR|g" $EXEC.sh
sed -i "s|{EXEC}|$EXEC|g" $EXEC.sh

chmod 755 $EXEC.sh
mv -f $EXEC.sh /etc/init.d/$EXEC

chkconfig --add $EXEC
