chiark / gitweb /
Make --quilt=gbp the default for dgit gbp-build.
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 9 Oct 2016 00:36:12 +0000 (01:36 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 10 Oct 2016 00:01:10 +0000 (01:01 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
debian/changelog
dgit
dgit.1

index e97cb3c1a644eb88b7e908bfe97a49a82ae5fbaf..c63b7e77a98fd2a10eace7a6ff5a54795348fe9c 100644 (file)
@@ -35,6 +35,7 @@ dgit (1.5~~) unstable; urgency=medium
     any Gbp-Pq headers (that we understand).
   * Several dgit-generated commits now have slightly better annotations
     from dgit about what it was doing.
     any Gbp-Pq headers (that we understand).
   * Several dgit-generated commits now have slightly better annotations
     from dgit about what it was doing.
+  * Make --quilt=gbp the default for dgit gbp-build.
 
   Infrastructure:
   * Better error handling in dgit-repos-policy-debian.
 
   Infrastructure:
   * Better error handling in dgit-repos-policy-debian.
diff --git a/dgit b/dgit
index 50011cce1bde6c9ea94ce28dd0530a99db2b09f3..150c11539a46bee1a46c32d256a33a99061bdcf4 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -4671,6 +4671,10 @@ sub cmd_build {
     printdone "build successful\n";
 }
 
     printdone "build successful\n";
 }
 
+sub pre_gbp_build {
+    $quilt_mode //= 'gbp';
+}
+
 sub cmd_gbp_build {
     my @dbp = @dpkgbuildpackage;
 
 sub cmd_gbp_build {
     my @dbp = @dpkgbuildpackage;
 
@@ -5101,6 +5105,9 @@ if (!@ARGV) {
 my $cmd = shift @ARGV;
 $cmd =~ y/-/_/;
 
 my $cmd = shift @ARGV;
 $cmd =~ y/-/_/;
 
+my $pre_fn = ${*::}{"pre_$cmd"};
+$pre_fn->() if $pre_fn;
+
 if (!defined $rmchanges) {
     local $access_forpush;
     $rmchanges = access_cfg_bool(0, 'rm-old-changes');
 if (!defined $rmchanges) {
     local $access_forpush;
     $rmchanges = access_cfg_bool(0, 'rm-old-changes');
diff --git a/dgit.1 b/dgit.1
index b3a4f9392be39fac79845503c5295aa5eda7c4d7..13666ea432cf08f14d33abf738d562fd0c1eba06 100644 (file)
--- a/dgit.1
+++ b/dgit.1
@@ -139,6 +139,9 @@ Runs
 with some suitable options.  Options and arguments after gbp-build
 will be passed on to git-buildpackage.
 
 with some suitable options.  Options and arguments after gbp-build
 will be passed on to git-buildpackage.
 
+By default this uses \-\-quilt=gbp, so HEAD should be a
+git-buildpackage style branch, not a patches-applied branch.
+
 Tagging, signing and actually uploading should be left to dgit push.
 .TP
 \fBdgit push\fR [\fIsuite\fP]
 Tagging, signing and actually uploading should be left to dgit push.
 .TP
 \fBdgit push\fR [\fIsuite\fP]
@@ -430,7 +433,7 @@ do not want your branch changed by dgit.
 is for use with git-buildpackage.
 Your HEAD is expected to be
 a patches-unapplied git branch, except that it might contain changes
 is for use with git-buildpackage.
 Your HEAD is expected to be
 a patches-unapplied git branch, except that it might contain changes
-to upstream .gitignore files.
+to upstream .gitignore files.  This is the default for dgit gbp-build.
 
 .B --quilt=dpm
 is for use with git-dpm.
 
 .B --quilt=dpm
 is for use with git-dpm.