RE: [PATCH v2] pull: abort if --ff-only is given and fast-forwarding is impossible
- From
Felipe Contreras <felipe.contreras@gmail.com>
- Date
- Jul 15, 2021, 09:55 UTC
- Message-ID
- <60f00611796d0_2e672085d@natae.notmuch>
- In-Reply-To
- <20210715050559.3371470-1-alexhenrie24@gmail.com>
Alex Henrie wrote:
Show 16 quoted lines
> The warning about pulling without specifying how to reconcile divergent > branches says that after setting pull.rebase to true, --ff-only can > still be passed on the command line to require a fast-forward. Make that > actually work. > > Per the discussion on the mailing list, explicitly passing --rebase on > the command line countermands pull.ff=only in the configuration or a > previous --ff-only on the command line. > > The --no-ff in `git pull --rebase --no-ff` is still ignored. > > Signed-off-by: Alex Henrie <alexhenrie24@gmail.com> > --- > This is the code I was working on when Elijah sent his patch set to > accomplish the same general goals. Mine is a less ambitious (and less > invasive) approach, but I don't care which solution wins.
This is a better approach than Elijah's because it doesn't fail if both pull.ff and pull.rebase are configured.
But there's still the problem that the new behavior cannot be configured.
-- Felipe Contreras