[lintian] 01/01: When checking latest-debian-changelog-entry-without-new-version ignore any change of epoch. (Closes: #889991)
This is an automated email from the git hooks/post-receive script.
lamby pushed a commit to branch master
in repository lintian.
commit 1cadac3c48bf361c2894d56f2ef6fdf28bc32e9e
Author: Chris Lamb <lamby@debian.org>
Date: Fri Feb 9 22:05:52 2018 +0000
When checking latest-debian-changelog-entry-without-new-version ignore any change of epoch. (Closes: #889991)
---
checks/changelog-file.desc | 3 +++
checks/changelog-file.pm | 8 ++++++--
debian/changelog | 3 +++
t/tests/changelog-file-general/debian/debian/changelog.in | 3 ++-
4 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/checks/changelog-file.desc b/checks/changelog-file.desc
index 9843234..1dff2df 100644
--- a/checks/changelog-file.desc
+++ b/checks/changelog-file.desc
@@ -210,6 +210,9 @@ Severity: normal
Certainty: certain
Info: The latest Debian changelog entry has a version number that's either
the same or smaller than the version number of the entry before.
+ .
+ All versions for a source package must be unique, even with a leading
+ epoch stripped off.
Tag: latest-debian-changelog-entry-changed-to-native
Severity: normal
diff --git a/checks/changelog-file.pm b/checks/changelog-file.pm
index fda5d8f..210d75e 100644
--- a/checks/changelog-file.pm
+++ b/checks/changelog-file.pm
@@ -318,8 +318,12 @@ sub run {
my $second_version = $entries[1]->Version;
if ($first_version and $second_version) {
tag 'latest-debian-changelog-entry-without-new-version'
- unless versions_gt($first_version, $second_version)
- or $entries[0]->Changes =~ /backport/i;
+ unless versions_gt(
+ $first_version =~ s/^([^:]+)://r,
+ $second_version =~ s/^([^:]+)://r
+ )
+ or $entries[0]->Changes =~ /backport/i
+ or $entries[0]->Source ne $entries[1]->Source;
tag 'latest-debian-changelog-entry-changed-to-native'
if $native_pkg and $second_version =~ m/-/;
}
diff --git a/debian/changelog b/debian/changelog
index ac125ce..b4e69db 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,9 @@ lintian (2.5.75) UNRELEASED; urgency=medium
XXX: generate tag summary
+ * checks/changelog-file.desc:
+ + [CL] When checking latest-debian-changelog-entry-without-new-version
+ ignore any change of epoch. (Closes: #889991)
* checks/patch-systems.{desc,pm}:
+ [CL] Avoid false positives when checking for typos by ignoring files
or patch descriptions that contain the words "typo" or "spelling".
diff --git a/t/tests/changelog-file-general/debian/debian/changelog.in b/t/tests/changelog-file-general/debian/debian/changelog.in
index 8b6e177..d828c35 100644
--- a/t/tests/changelog-file-general/debian/debian/changelog.in
+++ b/t/tests/changelog-file-general/debian/debian/changelog.in
@@ -1,4 +1,4 @@
-{$source} ({$version}) unstable; urgency=low
+{$source} (1:{$version}) unstable; urgency=low
* Test: {$testname}
@@ -21,6 +21,7 @@
üüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüü
* It might even fix TEMP-1234567-abcdef, though probably not.
+ * We refer to the epoch bump here.
-- {$author} {$date}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git
Reply to: