mirror of
https://github.com/weewx/weewx.git
synced 2026-04-18 00:26:57 -04:00
35 lines
754 B
Bash
Executable File
35 lines
754 B
Bash
Executable File
#!/bin/sh -e
|
|
# $Id$
|
|
# postrm script for weewx debian package
|
|
# Copyright 2013 Matthew Wall
|
|
#
|
|
# ways this script might be invoked:
|
|
#
|
|
# postrm remove
|
|
# postrm purge
|
|
# old-postrm upgrade new-version
|
|
# disappearer's-postrm disappear overwriter overwriter-version
|
|
# new-postrm failed-upgrade old-version
|
|
# new-postrm abort-install
|
|
# new-postrm abort-install old-version
|
|
# new-postrm abort-upgrade old-version
|
|
|
|
. /usr/share/debconf/confmodule
|
|
|
|
if [ "$1" != remove -a "$1" != purge ]; then
|
|
exit 0
|
|
fi
|
|
|
|
# remove the startup configuration
|
|
update-rc.d weewx remove > /dev/null
|
|
|
|
# restart apache only if it was running
|
|
#invoke-rc.d apache2 status && invoke-rc.d apache2 restart
|
|
|
|
if [ "$1" = purge ]; then
|
|
# remove any debconf entries
|
|
db_purge
|
|
fi
|
|
|
|
exit 0
|