chiark / gitweb /
dgit: Factor out debian/source/.. in check_not_dirty
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 11 Oct 2018 00:30:55 +0000 (01:30 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 11 Oct 2018 00:30:55 +0000 (01:30 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
dgit

diff --git a/dgit b/dgit
index 5754e45676393f15294a16cbc27e79512b8017ec..8df8f761baf9347ce341102b0fd5229aaf4fb03d 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -3818,9 +3818,10 @@ sub pull () {
 
 sub check_not_dirty () {
     my @forbid = qw(local-options local-patch-header);
+    @forbid = map { "debian/source/$_" } @forbid;
     foreach my $f (@forbid) {
-       if (stat_exists "debian/source/$f") {
-           fail f_ "git tree contains debian/source/%s", $f;
+       if (stat_exists $f) {
+           fail f_ "git tree contains %s", $f;
        }
     }