summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgit-debrebase5
1 files changed, 4 insertions, 1 deletions
diff --git a/git-debrebase b/git-debrebase
index 529286e..a0fc2aa 100755
--- a/git-debrebase
+++ b/git-debrebase
@@ -494,6 +494,7 @@ sub gbp_pq_export ($$$) {
# must be run in a workarea. $bname and patch-queue/$bname
# ought not to exist. Leaves you on patch-queue/$bname with
# the patches staged but not committed.
+ # returns 1 if there were any patches
printdebug "gbp_pq_export $bname $base $tip\n";
runcmd @git, qw(checkout -q -b), $bname, $base;
runcmd @git, qw(checkout -q -b), "patch-queue/$bname", $tip;
@@ -503,7 +504,9 @@ sub gbp_pq_export ($$$) {
{ local ($!,$?); copy('../gbp-pq-err', \*STDERR); }
failedcmd @gbp_cmd;
}
- runcmd @git, qw(add -f debian/patches) if stat_exists 'debian/patches';
+ return 0 unless stat_exists 'debian/patches';
+ runcmd @git, qw(add -f debian/patches);
+ return 1;
}