This file is indexed.

postinst is in metche 1:1.2.4-1.

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
#!/bin/sh

set -e

. /usr/share/debconf/confmodule

case "$1" in
  configure)
    TEMPFILE=`tempfile`
    cat "/usr/share/metche/config/metche.conf.default" > "$TEMPFILE"

    db_get metche/email
    EMAIL_ADDRESS="$RET"
    sed -e "s/^ *EMAIL_ADDRESS=.*/EMAIL_ADDRESS=\"$EMAIL_ADDRESS\"/" \
        -i "$TEMPFILE"

    db_get metche/changelog/type
    case "$RET" in
      "Single changelog file")
	db_get metche/changelog/file
	CHANGELOG_FILE="$RET"
	sed -e "s@^[# ]*CHANGELOG_FILE=.*@CHANGELOG_FILE=\"$CHANGELOG_FILE\"@" \
	    -e "s@^[# ]*CHANGELOG_DIR@#CHANGELOG_DIR@" -i "$TEMPFILE"
	;;
      "Multiple changelog files")
	db_get metche/changelog/directory
	CHANGELOG_DIR="$RET"
	sed -e "s@^[# ]*CHANGELOG_DIR=.*@CHANGELOG_DIR=\"$CHANGELOG_DIR\"@" \
	    -e "s@^[# ]*CHANGELOG_FILE@#CHANGELOG_FILE@" -i "$TEMPFILE"
	;;
      "No changelog monitoring")
	  sed -e "s@^[# ]*CHANGELOG_FILE@#CHANGELOG_FILE@" \
	      -e "s@^[# ]*CHANGELOG_DIR@#CHANGELOG_DIR@" -i "$TEMPFILE"
	;;
    esac

    ucf --debconf-ok --three-way "$TEMPFILE" "/etc/metche.conf"

    rm -f "$TEMPFILE"

    # Initialize metche data only when it was not configured before
    # (= no previous version number given as a second argument)
    if [ -z "$2" ]; then
        metche cron
    fi
  ;;

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

  *)
    echo "postinst called with unkwnow argument '$1'" >&2
    exit 0
  ;;
esac



exit 0

# vim: et sw=4