[pkg-bacula-commits] [bacula] 01/01: Use maintscript to remove old conffile

Sven Hartge hartge-guest at moszumanska.debian.org
Mon Jul 18 15:31:28 UTC 2016


This is an automated email from the git hooks/post-receive script.

hartge-guest pushed a commit to branch master-systemd
in repository bacula.

commit b5eb06fe0a091198de63e8ba798190d8b01b5470
Author: Sven Hartge <sven at svenhartge.de>
Date:   Mon Jul 18 17:19:50 2016 +0200

    Use maintscript to remove old conffile
    
    As always, there is a better and more Debian way to do things.
    Instead of wrongly reinventing the wheel, just use a maintscript
    with rm_conffile for dh_installdeb.
---
 debian/bacula-common.maintscript |  1 +
 debian/bacula-common.postinst    | 10 ----------
 2 files changed, 1 insertion(+), 10 deletions(-)

diff --git a/debian/bacula-common.maintscript b/debian/bacula-common.maintscript
new file mode 100644
index 0000000..70b2adb
--- /dev/null
+++ b/debian/bacula-common.maintscript
@@ -0,0 +1 @@
+rm_conffile /etc/tmpfiles.d/bacula.conf 7.4.3+dfsg-2~
diff --git a/debian/bacula-common.postinst b/debian/bacula-common.postinst
index 342affb..4d5ad92 100644
--- a/debian/bacula-common.postinst
+++ b/debian/bacula-common.postinst
@@ -16,16 +16,6 @@ case "$1" in
         . /usr/share/bacula-common/common-functions.dpkg
         readOrCreatePasswords # create our common passwords if needed
 
-	# Remove leftover /etc/tmpfiles.d/bacula.conf if it is identical
-	# to /usr/lib/tmpfiles.d/bacula.conf
-	if [ -f /etc/tmpfiles.d/bacula.conf ]; then
-		if diff /etc/tmpfiles.d/bacula.conf /usr/lib/tmpfiles.d/bacula.conf >/dev/null; then
-			rm /etc/tmpfiles.d/bacula.conf
-		else
-			echo "/etc/tmpfiles.d/bacula.conf and /usr/lib/tmpfiles.d/bacula.conf differ, please check contents manually" >&2
-		fi
-	fi
-
     ;;
 esac
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-bacula/bacula.git



More information about the pkg-bacula-commits mailing list