Re: merging bare repository

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

 



On Fri, May 13, 2011 at 02:51:32PM +0400, Ilya Basin wrote:

> on server:
>     [git@server]$ git clone --bare ssh://git@xxxxxxxx/git/project.git /git/project.git
> 
> on workstation:
>     [me@client]$ git clone ssh://git@server/git/project.git
>     [me@client]$ cd project
>     [me@client]$ touch aaa
>     [me@client]$ git add aaa
>     [me@client]$ git commit aaa -m abracadabra
>     [me@client]$ git push
> 
> back on server:
>     [git@server]$ git log
>     commit e5c871122cadfa4ed4d2ab488852ecdb803b4bd8
>     Author: Ilya Basin <>
>     Date:   Fri May 13 13:39:39 2011 +0400
> 
>         abracadabra
> 
> I want to merge with upstream
>     [git@server]$ git fetch
>     [git@server]$ git merge origin
>     fatal: This operation must be run in a work tree

Yeah, you need a work tree to do a merge, as there may be conflicts.
Moreover, you can't just do the merge via something like cron, as you
may need user intervention to resolve the conflicts.

So from your workstation, you'll want to do:

  git remote add upstream ssh://git@xxxxxxxx/git/project.git
  git pull upstream

whenever you feel like merging with upstream.

-Peff
--
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]