git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 5/5] pull: abort by default when fast-forwarding is not possible

From
Felipe Contreras <felipe.contreras@gmail.com>
Date
Jul 16, 2021, 18:13 UTC
Message-ID
<60f1cc4a71af9_3302082a@natae.notmuch>
In-Reply-To
<87czriy557.fsf@evledraar.gmail.com>
Ævar Arnfjörð Bjarmason wrote:
> On Thu, Jul 15 2021, Elijah Newren via GitGitGadget wrote:
Show 20 quoted lines
> >  int cmd_pull(int argc, const char **argv, const char *prefix)
> > @@ -1074,9 +1074,8 @@ int cmd_pull(int argc, const char **argv, const char *prefix)
> >  		if (opt_ff) {
> >  			if (!strcmp(opt_ff, "--ff-only"))
> >  				die_ff_impossible();
> > -		} else {
> > -			if (rebase_unspecified && opt_verbosity >= 0)
> > -				show_advice_pull_non_ff();
> > +		} else if (rebase_unspecified) {
> > +			die_pull_non_ff();
> >  		}
> 
> Here we should:
> 
>     show_advice_pull_non_ff();
>     die(_("some much briefer summary"))
> 
> I.e. we should not being showing giantic advice-y die() messages, the
> die messages should always be brief, but we might also show advice just
> before dying.
Indeed, just like my proposal does:
		diverging_advice();
		die(_("The pull was not fast-forward, either merge or rebase.\n"));
-- 
Felipe Contreras
Previous: Ævar Arnfjörð BjarmasonNext: Felipe Contreras
Message 25 of 26 in “Handle conflicting pull options”
  1. 0/5 Handle conflicting pull optionsElijah Newren via GitGitGadget, Jul 15, 2021
  2. 1/5 pull: move definitions of parse_config_rebase and parse_opt_rebaseElijah Newren via GitGitGadget, Jul 15, 2021
  3. 3/5 pull: handle conflicting rebase/merge options via last option winsElijah Newren via GitGitGadget, Jul 15, 2021
  4. Eric SunshineJul 15, 2021
  5. Elijah NewrenJul 15, 2021
  6. Felipe ContrerasJul 15, 2021
  7. Junio C HamanoJul 15, 2021
  8. Felipe ContrerasJul 15, 2021
  9. Elijah NewrenJul 15, 2021
  10. Junio C HamanoJul 15, 2021
  11. Elijah NewrenJul 15, 2021
  12. Junio C HamanoJul 15, 2021
  13. Elijah NewrenJul 16, 2021
  14. Junio C HamanoJul 16, 2021
  15. Felipe ContrerasJul 16, 2021
  16. Junio C HamanoJul 15, 2021
  17. Elijah NewrenJul 15, 2021
  18. 2/5 pull: convert OPT_PASSTHRU for fast-forward options to OPT_CALLBACKElijah Newren via GitGitGadget, Jul 15, 2021
  19. 4/5 pull: abort if --ff-only is given and fast-forwarding is impossibleAlex Henrie via GitGitGadget, Jul 15, 2021
  20. 5/5 pull: abort by default when fast-forwarding is not possibleElijah Newren via GitGitGadget, Jul 15, 2021
  21. Eric SunshineJul 15, 2021
  22. Elijah NewrenJul 15, 2021
  23. Felipe ContrerasJul 15, 2021
  24. Ævar Arnfjörð BjarmasonJul 16, 2021
  25. Felipe ContrerasJul 16, 2021
  26. Felipe ContrerasJul 15, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.