From: Michael Prokop Date: Mon, 18 May 2009 07:14:17 +0000 (+0200) Subject: Install haltlocal initscript in postinst script X-Git-Tag: v0.8.21~2 X-Git-Url: http://git.grml.org/?p=grml-autoconfig.git;a=commitdiff_plain;h=32e5d4dfe9956856074d95a1b4b535fac2fcbdcd Install haltlocal initscript in postinst script --- diff --git a/debian/changelog b/debian/changelog index a4eb48a..b39820b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +grml-autoconfig (0.8.21) unstable; urgency=low + + * Install haltlocal initscript in postinst script. + + -- Michael Prokop Mon, 18 May 2009 09:13:59 +0200 + grml-autoconfig (0.8.20) unstable; urgency=low * Use "speakup_..." for speakup bootoption. Thanks to Michael Whapples! diff --git a/debian/postinst b/debian/postinst index 2c1041c..3783fbe 100755 --- a/debian/postinst +++ b/debian/postinst @@ -6,9 +6,11 @@ if [ "$1" = "configure" ]; then # begin of "create special init scripts which won't be touched any more by grml" . /etc/grml/lsb-functions +DATE=$(date) + +# bootup INITSCRIPT=bootlocal INITNAME=/etc/init.d/${INITSCRIPT} -DATE=$(date) for initscript in ${INITNAME}.first ${INITNAME}.middle ${INITNAME}.last ; do if ! [ -r "$initscript" ] ; then @@ -34,8 +36,37 @@ done update-rc.d ${INITSCRIPT}.first start 1 S . >/dev/null update-rc.d ${INITSCRIPT}.middle start 29 2 . >/dev/null update-rc.d ${INITSCRIPT}.last start 99 2 . >/dev/null -# end of "create special init scripts which won't be touched any more by grml" +# shutdown +INITSCRIPT=haltlocal +INITNAME=/etc/init.d/${INITSCRIPT} + +for initscript in ${INITNAME}.first ${INITNAME}.middle ${INITNAME}.last ; do + if ! [ -r "$initscript" ] ; then + einfo "Creating ${initscript}" + cat >$initscript </dev/null +update-rc.d ${INITSCRIPT}.middle stop 29 0 1 6 . >/dev/null +update-rc.d ${INITSCRIPT}.last stop 99 0 1 6 . >/dev/null + +# end of "create special init scripts which won't be touched any more by grml" fi #DEBHELPER#