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

Re: [PATCH v2] Documentation/git-pull: clarify configuration

From
Junio C Hamano <gitster@pobox.com>
Date
Nov 10, 2010, 17:37 UTC
Message-ID
<7voc9xhyfx.fsf@alter.siamese.dyndns.org>
In-Reply-To
<1289373188-32543-1-git-send-email-martin.von.zweigbergk@gmail.com>
Martin von Zweigbergk <martin.von.zweigbergk@gmail.com> writes:
Show 23 quoted lines
> diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt
> index c50f7dc..055126e 100644
> --- a/Documentation/git-pull.txt
> +++ b/Documentation/git-pull.txt
> @@ -92,12 +92,15 @@ include::merge-options.txt[]
>  :git-pull: 1
>  
>  --rebase::
> -	Instead of a merge, perform a rebase after fetching.  If
> -	there is a remote ref for the upstream branch, and this branch
> -	was rebased since last fetched, the rebase uses that information
> -	to avoid rebasing non-local changes. To make this the default
> -	for branch `<name>`, set configuration `branch.<name>.rebase`
> -	to `true`.
> +	Instead of merging, rebase the current branch on top of the
> +	upstream branch after fetching.  If there is a remote-tracking
> +	branch corresponding to the upstream branch and the upstream
> +	branch was rebased since last fetched, the rebase uses that
> +	information to avoid rebasing non-local changes.
> +
> +	The default behavior is to merge rather than rebasing, but it
> +	can be overridden per branch with the `branch.<name>.rebase`
> +	configuration item (see git-config(1)).

The explanation looks correct in the sense that it does not say anything incorrect, and the description of non-local change exclusion in the first paragraph is more readable, I think.

But I am not sure if we want a separate paragraph here only to repeat a half of what the second paragraph in the DESCRIPTION section already said. The "default is merge" is implied by "Instead of merging" at the beginnig of this part anyway.

Also have you tried to actually format this and checked the result before submitting the patch?

Perhaps doing it like this may be better (no I didn't run AsciiDoc on it).
--rebase::
	Rebase the current branch on top of the upstream branch after
        fetching.  If there is a remote-tracking branch corresponding to
        the upstream branch and the upstream branch was rebased since last
        fetched, the rebase uses that information to avoid rebasing
        non-local changes.
+
See `branch.<name>.rebase` in linkgit:git-config[1] if you want to make
`git pull` always use `{litdd}rebase` instead of merging.
Previous: Martin von ZweigbergkNext: Martin von Zweigbergk
Message 4 of 6 in “Documentation/git-pull: clarify configuration”
  1. Documentation/git-pull: clarify configurationMartin von Zweigbergk, Nov 10, 2010
  2. Jonathan NiederNov 10, 2010
  3. Martin von ZweigbergkNov 11, 2010
  4. Junio C HamanoNov 10, 2010
  5. Martin von ZweigbergkNov 11, 2010
  6. Jonathan NiederNov 11, 2010

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.