summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--TODO2
-rw-r--r--debian/changelog1
-rwxr-xr-xdgit4
-rw-r--r--dgit.114
4 files changed, 16 insertions, 5 deletions
diff --git a/TODO b/TODO
index 0df45bd..a5999fe 100644
--- a/TODO
+++ b/TODO
@@ -1,5 +1,3 @@
---gpg= etc. @gpg should be in manual
-should pass @gpg to debsign
--ssh= etc. @ssh should be in manual
support SSH and DGIT_SSH
--dgit= etc. @dgit should be in manual
diff --git a/debian/changelog b/debian/changelog
index 16119b9..34f6cdb 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,7 @@ dgit (0.16~experimental2) experimental; urgency=low
* Some code motion and cleanups.
* push actually takes an optional suite, like it says in the synopsis.
* Command execution reports from --dry-run go to stderr.
+ * Support --gpg=... to provide a replacement command for gpg.
--
diff --git a/dgit b/dgit
index 6c1477c..3c24c2c 100755
--- a/dgit
+++ b/dgit
@@ -76,6 +76,8 @@ our %opts_opt_map = ('dget' => \@dget,
'ch' => \@changesopts,
'mergechanges' => \@mergechanges);
+our %opts_opt_cmdonly = ('gpg' => 1);
+
our $keyid;
our $debug = 0;
@@ -1134,6 +1136,7 @@ sub sign_changes ($) {
if ($sign) {
my @debsign_cmd = @debsign;
push @debsign_cmd, "-k$keyid" if defined $keyid;
+ push @debsign_cmd, "-p$pgp[0]" if $pgp[0] ne 'gpg';
push @debsign_cmd, $changesfile;
runcmd_ordryrun @debsign_cmd;
}
@@ -1690,6 +1693,7 @@ sub parseopts () {
push @ropts, $_;
$om->[0] = $2;
} elsif (m/^--(\w+):(.*)/s &&
+ !$opts_opt_cmdonly{$1} &&
($om = $opts_opt_map{$1})) {
push @ropts, $_;
push @$om, $2;
diff --git a/dgit.1 b/dgit.1
index b3f8f95..2f7cecc 100644
--- a/dgit.1
+++ b/dgit.1
@@ -236,9 +236,12 @@ Specifies alternative programs to use instead of
.BR dpkg-buildpackage ,
.BR dpkg-genchanges ,
.BR sbuild ,
+.BR gpg ,
or
.BR mergechanges .
-This applies only when the program is invoked directly by dgit.
+
+For dpkg-buildpackage, dpkg-genchanges, mergechanges and sbuild,
+this applies only when the program is invoked directly by dgit.
.TP
.RI \fB--dget:\fR option |\fB--dput:\fR option |...
Specifies a single additional option to pass to
@@ -252,9 +255,14 @@ Specifies a single additional option to pass to
or
.BR mergechanges .
Can be repeated as necessary.
-This applies only when the program is invoked directly by dgit.
-Usually, for passing options to dpkg-genchanges, use
+
+For dpkg-buildpackage, dpkg-genchanges, mergechanges and sbuild,
+this applies only when the program is invoked directly by dgit.
+Usually, for passing options to dpkg-genchanges, you should use
.BR --ch: \fIoption\fR.
+
+NB that --gpg:option is not supported (because debsign does not
+have that facility). But see -k.
.TP
.BR -d "\fIdistro\fR | " --distro= \fIdistro\fR
Specifies that the suite to be operated on is part of distro