This file is indexed.

preinst is in powernap 2.18-0ubuntu2.

This file is a maintainer script. It is executed when installing (*inst) or removing (*rm) the package.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/bin/sh

set -e

# Backup old confile
if [ -n "$2" ] && dpkg --compare-versions "$2" lt 2.0; then
	if [ -f /etc/powernap/config ]; then
		if md5sum /etc/powernap/config | grep -qs def76ff408c21dc74683a05d7c5fcc5a; then
			true
		else
			mv -f /etc/powernap/config /etc/powernap/config.old
			echo "PowerNap: The configuration format has changed"
			echo "Powernap: Moved /etc/powernap/config to /etc/powernap/config.old"
			echo "PowerNap: You may need to merge your customizations into /etc/powernap/config"
		fi
	fi
fi

# Automatically added by dh_installinit
if [ "$1" = install ] || [ "$1" = upgrade ]; then
	if [ -e "/etc/init.d/powernap" ] && [ -L "/etc/init.d/powernap" ] \
	   && [ $(readlink -f "/etc/init.d/powernap") = /lib/init/upstart-job ]
	then
		rm -f "/etc/init.d/powernap"
	fi
fi
# End automatically added section


exit 0