~ubuntu-branches/ubuntu/precise/checkbox/precise

« back to all changes in this revision

Viewing changes to debian/checkbox.postrm

  • Committer: Bazaar Package Importer
  • Author(s): Marc Tardif
  • Date: 2009-01-20 16:46:15 UTC
  • Revision ID: james.westby@ubuntu.com-20090120164615-7iz6nmlef41h4vx2
Tags: 0.4
* Setup bzr-builddeb in native mode.
* Removed LGPL notice from the copyright file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /bin/sh -e
 
2
 
 
3
name=`basename $0 .postrm`
 
4
base=`echo $name | cut -d "-" -f "1"`
 
5
file="/etc/$base.d/$name.ini"
 
6
 
 
7
case "$1" in
 
8
    purge)
 
9
        # mimic dpkg as closely as possible, so remove configuration
 
10
        # files with dpkg backup extensions too:
 
11
        for ext in '~' '%' .bak .dpkg-tmp .dpkg-new .dpkg-old .dpkg-dist;  do
 
12
            rm -f $file$ext
 
13
        done
 
14
 
 
15
        # remove the configuration file itself
 
16
        rm -f $file
 
17
 
 
18
        # and finally clear it out from the ucf database
 
19
        ucf --purge $file
 
20
        ;;
 
21
    remove|disappear|upgrade|failed-upgrade|abort-install|abort-upgrade)
 
22
        ;;
 
23
    *)
 
24
        echo "$0: didn't understand being called with \`$1'" 1>&2
 
25
        exit 0
 
26
        ;;
 
27
esac
 
28
 
 
29
#DEBHELPER#