[lintian] 01/01: Warn if a "Team upload" (ie. that string is present in the changelog) but the uploader is among the Maintainer/Uploaders. (Closes: #882954)
This is an automated email from the git hooks/post-receive script.
lamby pushed a commit to branch master
in repository lintian.
commit 35480565fd0588b397afc025374936f3c9cd1b9d
Author: Chris Lamb <lamby@debian.org>
Date: Tue Nov 28 20:57:08 2017 +0900
Warn if a "Team upload" (ie. that string is present in the changelog) but the uploader is among the Maintainer/Uploaders. (Closes: #882954)
---
checks/nmu.desc | 6 ++++++
checks/nmu.pm | 1 +
debian/changelog | 5 +++++
t/tests/nmu-unnecessary-team-upload/debian/debian/changelog.in | 6 ++++++
t/tests/nmu-unnecessary-team-upload/desc | 5 +++++
t/tests/nmu-unnecessary-team-upload/tags | 1 +
6 files changed, 24 insertions(+)
diff --git a/checks/nmu.desc b/checks/nmu.desc
index 1b9fd67..1aed82a 100644
--- a/checks/nmu.desc
+++ b/checks/nmu.desc
@@ -26,6 +26,12 @@ Info: A team upload (uploading a package from the same team without adding
get a NMU revision number. Team uploads are recognized by the string
"team upload" on the first line of the changelog file.
+Tag: unnecessary-team-upload
+Severity: normal
+Certainty: certain
+Info: The <tt>debian/changelog</tt> file refers to a "Team upload" but the
+ uploader is listed amongst the Maintainer/Uploaders.
+
Tag: source-nmu-has-incorrect-version-number
Severity: normal
Certainty: certain
diff --git a/checks/nmu.pm b/checks/nmu.pm
index d5c59a1..ea48e0e 100644
--- a/checks/nmu.pm
+++ b/checks/nmu.pm
@@ -115,6 +115,7 @@ sub run {
} elsif ($changelog_mentions_team_upload) {
tag 'team-upload-has-incorrect-version-number', $version
if $version_nmuness == 1;
+ tag 'unnecessary-team-upload' unless $upload_is_nmu;
} else {
# Local packages may be either NMUs or not.
unless ($changelog_mentions_local || $version_local) {
diff --git a/debian/changelog b/debian/changelog
index d925d96..4d5417d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,11 @@ lintian (2.5.61) UNRELEASED; urgency=medium
XXX: generate tag summary
+ * checks/nmu.{desc,pm}:
+ + [CL] Warn if a "Team upload" (ie. that string is present in the
+ changelog) but the uploader is among the Maintainer/Uploaders.
+ (Closes: #882954)
+
-- Chris Lamb <lamby@debian.org> Sun, 26 Nov 2017 11:51:35 +0900
lintian (2.5.60) unstable; urgency=medium
diff --git a/t/tests/nmu-unnecessary-team-upload/debian/debian/changelog.in b/t/tests/nmu-unnecessary-team-upload/debian/debian/changelog.in
new file mode 100644
index 0000000..2a31283
--- /dev/null
+++ b/t/tests/nmu-unnecessary-team-upload/debian/debian/changelog.in
@@ -0,0 +1,6 @@
+{$source} ({$version}) unstable; urgency=low
+
+ * Team upload.
+ * Suppress "should close ITP bug" messages. (Closes: #123456)
+
+ -- {$author} {$date}
diff --git a/t/tests/nmu-unnecessary-team-upload/desc b/t/tests/nmu-unnecessary-team-upload/desc
new file mode 100644
index 0000000..50b3755
--- /dev/null
+++ b/t/tests/nmu-unnecessary-team-upload/desc
@@ -0,0 +1,5 @@
+Testname: nmu-unnecessary-team-upload
+Version: 1.0
+Description: Test for unnecessary team uploads
+Test-For:
+ unnecessary-team-upload
diff --git a/t/tests/nmu-unnecessary-team-upload/tags b/t/tests/nmu-unnecessary-team-upload/tags
new file mode 100644
index 0000000..3670d7f
--- /dev/null
+++ b/t/tests/nmu-unnecessary-team-upload/tags
@@ -0,0 +1 @@
+W: nmu-unnecessary-team-upload source: unnecessary-team-upload
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git
Reply to: