[SCM] Debian packaging of wesnoth branch, devel, updated. debian/1.9.2-1-1-g4adf5f1

Gerfried Fuchs rhonda at debian.at
Thu Nov 18 16:59:15 UTC 2010


The following commit has been merged in the devel branch:
commit 4adf5f1424de3e824bf0a456774eaeee54632b1d
Author: Gerfried Fuchs <rhonda at debian.at>
Date:   Thu Nov 18 08:03:36 2010 +0100

    Fix wesnoth-*-core.postinst code

diff --git a/debian/changelog b/debian/changelog
index 57fcd9c..d1853d7 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+wesnoth-1.9 (1:1.9.2-2) unstable; urgency=low
+
+  * Fix wesnoth-*-core.postinst code to not return error (closes: #601859)
+
+ -- 
+
 wesnoth-1.9 (1:1.9.2-1) unstable; urgency=low
 
   * New upstream devel release.
diff --git a/debian/wesnoth-1.9-core.postinst b/debian/wesnoth-1.9-core.postinst
index 248c396..9bf0bc0 100644
--- a/debian/wesnoth-1.9-core.postinst
+++ b/debian/wesnoth-1.9-core.postinst
@@ -9,8 +9,7 @@ divert_oldfiles()
 {
 	# programs
 	for i in wesnoth wesnoth-nolog wesnoth-smallgui wesnoth-editor; do
-		dpkg-divert --list /usr/games/$i | grep -q /usr/games/$i
-		if [ $? != 0 ]; then
+		if ! dpkg-divert --list /usr/games/$i | grep -q /usr/games/$i; then
 			dpkg-divert --package wesnoth-1.9-core \
 				--divert /usr/games/$i-old \
 				--rename /usr/games/$i
@@ -20,8 +19,7 @@ divert_oldfiles()
 	# manpages
 	for i in ca_ES at valencia cs da de en_GB es et fi fr gl hu it ja \
 		lt nl pl sk sr sr at latin sv tr zh_CN zh_TW; do
-		dpkg-divert --list /usr/share/man/$i/man6/wesnoth.6.gz | grep -q /usr/share/man/$i/man6/wesnoth.6.gz
-		if [ $? != 0 ]; then
+		if ! dpkg-divert --list /usr/share/man/$i/man6/wesnoth.6.gz | grep -q /usr/share/man/$i/man6/wesnoth.6.gz; then
 			dpkg-divert --package wesnoth-1.9-core \
 				--divert /usr/share/man/$i/man6/wesnoth-old.6.gz \
 				--rename /usr/share/man/$i/man6/wesnoth.6.gz
diff --git a/debian/wesnoth-BRANCH-core.postinst.in b/debian/wesnoth-BRANCH-core.postinst.in
index f648798..339a547 100644
--- a/debian/wesnoth-BRANCH-core.postinst.in
+++ b/debian/wesnoth-BRANCH-core.postinst.in
@@ -9,8 +9,7 @@ divert_oldfiles()
 {
 	# programs
 	for i in wesnoth wesnoth-nolog wesnoth-smallgui wesnoth-editor; do
-		dpkg-divert --list /usr/games/$i | grep -q /usr/games/$i
-		if [ $? != 0 ]; then
+		if ! dpkg-divert --list /usr/games/$i | grep -q /usr/games/$i; then
 			dpkg-divert --package wesnoth-BRANCH-core \
 				--divert /usr/games/$i-old \
 				--rename /usr/games/$i
@@ -20,8 +19,7 @@ divert_oldfiles()
 	# manpages
 	for i in ca_ES at valencia cs da de en_GB es et fi fr gl hu it ja \
 		lt nl pl sk sr sr at latin sv tr zh_CN zh_TW; do
-		dpkg-divert --list /usr/share/man/$i/man6/wesnoth.6.gz | grep -q /usr/share/man/$i/man6/wesnoth.6.gz
-		if [ $? != 0 ]; then
+		if ! dpkg-divert --list /usr/share/man/$i/man6/wesnoth.6.gz | grep -q /usr/share/man/$i/man6/wesnoth.6.gz; then
 			dpkg-divert --package wesnoth-BRANCH-core \
 				--divert /usr/share/man/$i/man6/wesnoth-old.6.gz \
 				--rename /usr/share/man/$i/man6/wesnoth.6.gz

-- 
Debian packaging of wesnoth



More information about the Pkg-games-commits mailing list