diff options
author | Jeroen Schot <schot@A-Eskwadraat.nl> | 2011-04-22 12:15:10 +0200 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2011-04-25 19:24:53 -0400 |
commit | 3390e19f8a2947295551371c8ab2839573a1dca1 (patch) | |
tree | da41341f01c948a5dd81d51e80f9b6d9387ed465 /autoscripts/postrm-ucf | |
parent | e45627bda017b1c83cffc506355d8112f7b2989c (diff) |
Bug#213078: debhelper: please consider providing dh_ucf
Here is a patch against the master branch that adds such a command
called dh_installucf. It also registers the conffiles with ucfr and
removes stray ucf-{new,old,dist} files on purge.
Diffstat (limited to 'autoscripts/postrm-ucf')
-rw-r--r-- | autoscripts/postrm-ucf | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/autoscripts/postrm-ucf b/autoscripts/postrm-ucf new file mode 100644 index 00000000..47237a41 --- /dev/null +++ b/autoscripts/postrm-ucf @@ -0,0 +1,12 @@ +if [ "$1" = "purge" ]; then + for ext in .ucf-new .ucf-old .ucf-dist ""; do + rm -f #UCFDEST#$ext + done + + if [ -x `which ucf 2>/dev/null`]; then + ucf --purge #UCFDEST# + fi + if [ -x `which ucfr 2>/dev/null`]; then + ucfr --purge #PACKAGE# #UCFDEST# + fi +fi |