diff options
author | Thadeu Lima de Souza Cascardo <cascardo@debian.org> | 2017-10-24 12:30:47 -0200 |
---|---|---|
committer | Louis Bouchard <louis@ubuntu.com> | 2017-11-01 14:39:39 +0100 |
commit | 1d98c22f2a6b53d232329bd40c5335974cd1a3a6 (patch) | |
tree | 752bd4c689b7e0d1f36b88f978227beada8a029a /debian/kdump-tools.postrm | |
parent | a54ad2b2fc1e91ba1e9758427b42bb67300ddf17 (diff) |
Add ucf support
/etc/default/kdump-tools was already changed by the maintainer script,
so it should not be a conffile. ucf allows the maintainer scripts to ask
the user about changes done by the user to the config file.
Invoking debconf first in the script is desired, because the frontend
might exec and invoke the script itself again. Also, we install the
generated file instead of the original file, as we will replace some of
the settings. (Closes: 877250)
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@debian.org>
Diffstat (limited to 'debian/kdump-tools.postrm')
-rwxr-xr-x | debian/kdump-tools.postrm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/debian/kdump-tools.postrm b/debian/kdump-tools.postrm index b8921f4..1f078af 100755 --- a/debian/kdump-tools.postrm +++ b/debian/kdump-tools.postrm @@ -21,6 +21,14 @@ case "$1" in ;; purge) rm -rf /var/lib/kdump + if which ucf > /dev/null 2>&1; then + ucf --purge /etc/default/kdump-tools + ucfr -p kdump-tools /etc/default/kdump-tools + fi + rm -f /etc/default/kdump-tools + for i in new old dist; do + rm -f /etc/default/kdump-tools.ucf-$i + done ;; esac |