Re: Merging into a current branch

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

 



Geoff Russell <geoffrey.russell@xxxxxxxxx> wrote:
> Is there any reason why
> 
> git fetch origin branchX:branchX
> 
> fails if I am on branchX?   All I want to do is fast forward it.

Yes.

A fetch will *only* update the branch.  If the branch is your current
branch it won't update the working directory.  This safety check
is to prevent the branch from updating, but the working directory
staying unchanged, and the resulting git-status output looking like
you just undid all of the recent work done on branchX of origin.

Try git-pull instead:

  git pull origin branchX


-- 
Shawn.
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux