chiark / gitweb /
Split brain: Actually get gbp pq output back onto dgit-view branch
[dgit.git] / dgit
diff --git a/dgit b/dgit
index 4af8f34cd2b21ab71b08529c9e0aaf2b6efe8db6..0812f32ae2e48338a2686ffae70bfcb5050bc580 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -2575,6 +2575,9 @@ sub quiltify_splitbrain ($$$$$) {
        progress "creating patches-applied version using gbp-pq";
        open STDOUT, ">/dev/null" or die $!;
        runcmd shell_cmd 'exec >/dev/null', @gbppq, qw(import);
+       # gbp-pq import creates a fresh branch; push back to dgit-view
+       runcmd @git, qw(update-ref refs/heads/dgit-view HEAD);
+       runcmd @git, qw(checkout dgit-view);
     }
     if (($diffbits->{H2O} & 02) && # user has modified .gitignore
        !($diffbits->{O2A} & 02)) { # patches do not change .gitignore