File: postinst

package info (click to toggle)
isatapd 0.9.7-5.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 584 kB
  • sloc: ansic: 1,342; sh: 1,139; makefile: 26
file content (18 lines) | stat: -rw-r--r-- 465 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

set -e

# Handle upgrades from versions supporting RUN in /etc/default/isatapd.
# Disable the service properly if RUN is not set to "yes"
if [ "$1" = 'configure' ] && [ -f /etc/default/isatapd ] ; then
	if [ -n "$2" ] && dpkg --compare-versions "$2" lt 0.9.7 ; then
		. /etc/default/isatapd
		if [ -n "$RUN" ] && [ "$RUN" != "yes" ]; then
			update-rc.d isatapd disable > /dev/null
			deb-systemd-helper disable isatapd.service
		fi
	fi
fi

#DEBHELPER#