chiark / gitweb /
No longer tolerate a multitude of .changes files when doing push.
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 7 Nov 2015 13:13:59 +0000 (13:13 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 1 Jul 2016 22:53:45 +0000 (23:53 +0100)
Instead, insist on a single one.  This eliminates a potential for a
variety of surprises, where dgit would upload something different to
the user expected.

We no longer need to behave this way because nowadays the sbuild build
(which was the real use case, because it would generate a .source and
a .ARCH changes as well as the final .multi) renames the intermediate
changes files.

Also --rm-old-changes helps.

debian/changelog
dgit
dgit.1

index b02081ee339bbaadc9f13f91832e16a84c22f6ef..331a316832cd73f8424c6f37f071244dd5851900 100644 (file)
@@ -18,6 +18,8 @@ dgit (1.5~~) unstable; urgency=medium
   * Introduce --rm-old-changes to delete previous builds' changes files.
   * Remove any pre-existing _source.changes file before building source,
     as a safety check.
+  * No longer tolerate a multitude of .changes files when doing push.
+    Instead, insist on a single one.
 
   Documentation:
   * Document the dgit-distro.DISTRO.quilt-mode config setting.
diff --git a/dgit b/dgit
index 9803b13badd507a570d1d04ac77c045b57f6893e..e59060d240d2d3977a76d0319008f57c1f0f728b 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -2003,18 +2003,13 @@ END
     }
     my $head = git_rev_parse('HEAD');
     if (!$changesfile) {
-       my $multi = "$buildproductsdir/".changespat $cversion,'multi';
-       if (stat_exists "$multi") {
-           $changesfile = $multi;
-       } else {
-           my $pat = changespat $cversion;
-           my @cs = glob "$buildproductsdir/$pat";
-           fail "failed to find unique changes file".
-               " (looked for $pat in $buildproductsdir, or $multi);".
-               " perhaps you need to use dgit -C"
-               unless @cs==1;
-           ($changesfile) = @cs;
-       }
+       my $pat = changespat $cversion;
+       my @cs = glob "$buildproductsdir/$pat";
+       fail "failed to find unique changes file".
+           " (looked for $pat in $buildproductsdir);".
+           " perhaps you need to use dgit -C"
+           unless @cs==1;
+       ($changesfile) = @cs;
     } else {
        $changesfile = "$buildproductsdir/$changesfile";
     }
diff --git a/dgit.1 b/dgit.1
index d3f37029679076514a426fa6900f1c7f9661621f..588aac66001e7703a78e48680d8784adff0879cf 100644 (file)
--- a/dgit.1
+++ b/dgit.1
@@ -514,8 +514,7 @@ How to set this up is not yet documented.
 .BI -C changesfile
 Specifies the .changes file which is to be uploaded.  By default
 dgit push looks for single .changes file in the parent directory whose
-filename suggests it is for the right package and version - or,
-if there is a _multi.changes file, dgit uses that.
+filename suggests it is for the right package and version.
 
 If the specified
 .I changesfile