This file is indexed.

postinst is in ntfs-3g 1:2012.1.15AR.1-1ubuntu1.

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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
#!/bin/sh

set -e

. /usr/share/debconf/confmodule

_CONFFILE="/etc/default/ntfs-3g"

case "${1}" in
	configure)
		db_get ntfs-3g/setuid-root
		NTFS3G_SETUID_ROOT="${RET}" # boolean

		db_get ntfs-3g/initramfs
		NTFS3G_INITRAMFS="${RET}" # boolean

		db_stop

		if [ ! -e "${_CONFFILE}" ]
		then

cat > "${_CONFFILE}" << EOF
# /etc/default/ntfs-3g

NTFS3G_INITRAMFS="${NTFS3G_INITRAMFS}"
EOF
		fi

		cp -a -f "${_CONFFILE}" "${_CONFFILE}.tmp"

		# If the admin deleted or commented some variables but then set
		# them via debconf, (re-)add them to the config file.

		test -z "${NTFS3G_INITRAMFS}" || \
		grep -Eq '^ *NTFS3G_INITRAMFS=' "${_CONFFILE}" || \
		echo "NTFS3G_INITRAMFS=" >> "${_CONFFILE}"

		sed -e "s|^ *NTFS3G_INITRAMFS=.*|NTFS3G_INITRAMFS=\"${NTFS3G_INITRAMFS}\"|" \
		< "${_CONFFILE}" > "${_CONFFILE}.tmp"

		mv -f "${_CONFFILE}.tmp" "${_CONFFILE}"

		case "${NTFS3G_SETUID_ROOT}" in
			true)
				_MODE="4755"
				;;

			false)
				_MODE="0755"
				;;
		esac

		if [ -x /usr/sbin/dpkg-statoverride ] && \
		   ! /usr/sbin/dpkg-statoverride --list /bin/ntfs-3g >/dev/null
		then
			chown root:root /bin/ntfs-3g
			chmod ${_MODE} /bin/ntfs-3g
		fi

		case "${NTFS3G_INITRAMFS}" in
			true)
				if [ -x /usr/sbin/update-initramfs ]
				then
					update-initramfs -u
				fi
				;;
		esac
		;;

	abort-upgrade|abort-remove|abort-deconfigure)

		;;

	*)
		echo "postinst called with unknown argument \`${1}'" >&2
		exit 1
		;;
esac

# Automatically added by dh_makeshlibs
if [ "$1" = "configure" ]; then
	ldconfig
fi
# End automatically added section


exit 0