From 29302373129946046c6b461103d12f6b6bf9f908 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 20 May 2019 21:43:41 +0100 Subject: dgit: split brain reorg: Always _needed in split brain quilt modss The only differences are: 1. Call quiltify_splitbrain_needed earlier. This is of no consequence. 2. Call it even dpm mode when .gitignore was not edited. This is actually somewhat more correct. In dpm mode we are very likely later going to need split brain to keep the pseudomerge of the dgit view off the maintainer branch. And in fact that is what will happen because dopush fetches the quilt view from the cache and that sets $split_brain unconditionally. With the current code structure dgit's quilt fixup imagines that it can do a quilt fixup for dpm mode without split brain, when the .gitignore is not edited. But actually what is happening is that this is an empty tree fixup, and the history inclusion *will* be done split brain, but later. So overall this change will have no actual overall effect. But it is a move towards helping untangle the quilt mode from split brain. Signed-off-by: Ian Jackson --- dgit | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dgit') diff --git a/dgit b/dgit index 3662282..99bd51a 100755 --- a/dgit +++ b/dgit @@ -5400,6 +5400,8 @@ sub quiltify_splitbrain ($$$$$$$) { local $ENV{GIT_AUTHOR_EMAIL} = $authline[1]; local $ENV{GIT_AUTHOR_DATE} = $authline[2]; + quiltify_splitbrain_needed(); + my $fulldiffhint = sub { my ($x,$y) = @_; my $cmd = "git diff $x $y -- :/ ':!debian'"; @@ -5430,7 +5432,6 @@ END } if ($quilt_mode =~ m/gbp|unapplied/ && ($diffbits->{O2A} & 01)) { # some patches - quiltify_splitbrain_needed(); progress __ "dgit view: creating patches-applied version using gbp pq"; runcmd shell_cmd 'exec >/dev/null', gbp_pq, qw(import); # gbp pq import creates a fresh branch; push back to dgit-view @@ -5447,7 +5448,6 @@ END } if (($diffbits->{O2H} & 02) && # user has modified .gitignore !($diffbits->{O2A} & 02)) { # patches do not change .gitignore - quiltify_splitbrain_needed(); progress __ "dgit view: creating patch to represent .gitignore changes"; ensuredir "debian/patches"; -- cgit v1.2.3