Re: [PATCH] docs: rebasing-and-merging: Drop wrong statement about git

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> writes:

> From: Uwe Kleine-König <uwe@xxxxxxxxxxxxxxxxx>
>
> The "^0" doesn't have the described effect to only do fast-forward merges.
> For example
>
> 	git checkout 055efab3120b
> 	git merge v5.2-rc1^0
>
> creates a normal merge commit. In fact "v5.2-rc1^0" only refers to the
> commit the tag v5.2-rc1 points to.

So that pattern came straight from Linus, and it still works fine for me
- just tried it and got the expected fast-forward.  Maybe you have
something in your git configuration that makes things behave
differently?

That said...

> Fixes: d95ea1a4e1fb ("docs: Add a document on repository management")
> Signed-off-by: Uwe Kleine-König <uwe@xxxxxxxxxxxxxxxxx>
> ---
>  Documentation/maintainer/rebasing-and-merging.rst | 6 +-----
>  1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/Documentation/maintainer/rebasing-and-merging.rst b/Documentation/maintainer/rebasing-and-merging.rst
> index 09f988e7fa71..85800ce95ae5 100644
> --- a/Documentation/maintainer/rebasing-and-merging.rst
> +++ b/Documentation/maintainer/rebasing-and-merging.rst
> @@ -213,11 +213,7 @@ point rather than some random spot.  If your upstream-bound branch has
>  emptied entirely into the mainline during the merge window, you can pull it
>  forward with a command like::
>  
> -  git merge v5.2-rc1^0
> -
> -The "^0" will cause Git to do a fast-forward merge (which should be
> -possible in this situation), thus avoiding the addition of a spurious merge
> -commit.
> +  git merge --ff-only v5.2-rc1
>  

Git was fixed a couple of years or so ago to do the fast-forward by
default when it can, so the original advice in this file is unnecessary
- as is --ff-only (most of the time).  So the patch is worth applying,
but I may tweak the changelog some.

Thanks,

jon




[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux