File: prerm

package info (click to toggle)
libapache-mod-random 1.4-10
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 152 kB
  • ctags: 59
  • sloc: ansic: 318; sh: 170; makefile: 90
file content (42 lines) | stat: -rw-r--r-- 902 bytes parent folder | download
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
#!/bin/sh -e

# Standard prerm script for apache modules
# Written April 2006 by Pawel Wiecek <coven@debian.org>

MODULE=mod_random

# Source debconf library.
. /usr/share/debconf/confmodule

case "$1" in
  remove | deconfigure)
    db_get shared/apache-modules/counters/remove
    COUNT="$RET"
    db_get shared/apache-modules/counters/remove_list
    LIST="$RET"
    if echo $LIST | sed -e 's/,/,\n/g' | egrep -q "^$MODULE,?$"
    then
      # already added, nothing to do
      :
    else
      # add this module to list & counter
      let COUNT++ || true
      LIST="$LIST,$MODULE"
      db_set shared/apache-modules/counters/remove "$COUNT"
      db_set shared/apache-modules/counters/remove_list "$LIST"
    fi
    ;;

  upgrade | failed-upgrade )
    # nothing to do here
    ;;
    
  *)
    echo "$0: didn't understand being called with \`$1'" >&2
    exit 1
    ;;
esac

#DEBHELPER#

exit 0