chiark / gitweb /
dgit: Combine option parsing of -wd and -wdd
[dgit.git] / dgit
diff --git a/dgit b/dgit
index de697a15a22a1c1aeb5b84ef23e931baf30023a4..57e1e40d13d5c848b91a49ddd756d5bae27d1a78 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -7262,12 +7262,10 @@ sub parseopts () {
                } elsif (s/^-wgf$//s) {
                    push @ropts, $&;
                    $cleanmode = 'git-ff';
-               } elsif (s/^-wd$//s) {
+               } elsif (s/^-wd(d?)$//s) {
                    push @ropts, $&;
                    $cleanmode = 'dpkg-source';
-               } elsif (s/^-wdd$//s) {
-                   push @ropts, $&;
-                   $cleanmode = 'dpkg-source-d';
+                   $cleanmode .= '-d' if $1;
                } elsif (s/^-wc$//s) {
                    push @ropts, $&;
                    $cleanmode = 'check';