[lintian] 01/01: Avoid false positive for maintainer-script-should-not-use-update-alternatives-set not so certain
This is an automated email from the git hooks/post-receive script.
broucaries-guest pushed a commit to branch master
in repository lintian.
commit 35c81cd1ef0a41b3776870b85313912f8d04cb04
Author: Bastien ROUCARIÈS <roucaries.bastien+debian@gmail.com>
Date: Wed May 7 09:53:52 2014 +0200
Avoid false positive for maintainer-script-should-not-use-update-alternatives-set not so certain
http://lintian.debian.org/tags/maintainer-script-should-not-use-update-alternatives-set.html >
claim that the check is certain, and that the issue affects the
initscripts package. The code in question in the initscripts.postinst
file look like this:
echo "You can use update-alternatives --config runsystem to select"
echo "the runsystem to use."
---
data/scripts/maintainer-script-bad-command | 2 +-
debian/changelog | 4 ++++
t/tests/scripts-maintainer-general/debian/debian/postinst | 4 ++++
3 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/data/scripts/maintainer-script-bad-command b/data/scripts/maintainer-script-bad-command
index cf9ecb1..4b5cd56 100644
--- a/data/scripts/maintainer-script-bad-command
+++ b/data/scripts/maintainer-script-bad-command
@@ -40,7 +40,7 @@ maintainer-script-should-not-use-install-sgmlcatalog ~~ 1 ~~
maintainer-script-should-not-use-service ~~ 1 ~~ ~~ ~~${LEADIN}service\b
maintainer-script-should-not-use-start-stop-daemon ~~ 0 ~~ ~~ ~~\bstart-stop-daemon(?=\s)(?!.*\s--stop\b)
maintainer-script-should-not-use-update-alternatives-remove ~~ 1 ~~ ~~^postrm$ ~~\b update\-alternatives\s+\-\-remove\b
-maintainer-script-should-not-use-update-alternatives-set ~~ 1 ~~ ~~ ~~\b update\-alternatives\s+\-\-(?:set|set\-selections|config)\b
+maintainer-script-should-not-use-update-alternatives-set ~~ 1 ~~ ~~ ~~^(?!\s*echo\s+["'][^'"]*)\bupdate\-alternatives\s+\-\-(?:set|set\-selections|config)\b
# sendmail use override do not change it now
suidregister-used-in-maintainer-script ~~ 1 ~~ ~~ ~~\bsuidregister\b
diff --git a/debian/changelog b/debian/changelog
index f90fc9a..5ef3515 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -59,6 +59,10 @@ lintian (2.5.23) UNRELEASED; urgency=medium
Thijs Kinkhorst. (Closes: #711193)
* data/java/constants:
+ [SL] introduce this file to specify JDK values
+ * data/scripts/maintainer-script-bad-command:
+ + [BR] Avoid a false positive for
+ maintainer-script-should-not-use-update-alternatives-set.
+ (Closes: #745568).
* debian/control:
+ [NT] Add Build-Depends on po4a.
diff --git a/t/tests/scripts-maintainer-general/debian/debian/postinst b/t/tests/scripts-maintainer-general/debian/debian/postinst
index 2be496a..96e0d04 100755
--- a/t/tests/scripts-maintainer-general/debian/debian/postinst
+++ b/t/tests/scripts-maintainer-general/debian/debian/postinst
@@ -166,4 +166,8 @@ adduser --system --ingroup smmta --home "/var/lib/sendmail" \
--disabled-password \
--quiet --gecos 'Mail Transfer Agent' smmta;
+# false positive
+echo "You can use update-alternatives --config runsystem to select"
+echo "the runsystem to use."
+
#DEBHELPER#
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git
Reply to: