Re: Urgent: Issue with GIT ...
- From
Kevin <ikke@ikke.info>
- Date
- Jun 26, 2012, 06:08 UTC
- Message-ID
- <CAO54GHA=R1CyspFrC1n-JLVbm5eE+roXLBv6hFL5M1BHGAcVBA@mail.gmail.com>
- In-Reply-To
- <slrnjugobd.8ie.andy@atom.gently.org.uk>
The difference between bare and non-bare repositories is explained here [1].
In this setup, you should only pull from both repositories, not push to the other repository. If you want to push things, you should use a bare repository that both repositories can access and push to.
[1]: http://bare-vs-nonbare.gitrecipes.de/
On Mon, Jun 25, 2012 at 3:02 PM, Andy Hawkins <andy@gently.org.uk> wrote:
Show 31 quoted lines
> > Hi, > > In article <1340624980925-7562097.post@n2.nabble.com>, > guruprasad<guruprasadkinI@gmail.com> wrote: > > 5) If i do some changes to files in B, commit and push to remote branch, > > I > > am unable to pull the changes done and merge into A. I have set > > "receive.denycurrentbranch=ignore" in git config. > > Sounds like you're trying to push into a remote non-bare repository. > > What I'd do is: > > 1. On 'A', create a bare repository. > 2. Somewhere else on 'A', clone this repository. Work and push to the bare > in step 1 when necessary. > 3. On 'B', also clone the repository from 1. Work and push to the bare > when > necessary. > > I don't think it's a good idea to push to a repository that has checked > out > files. I seem to remember this being mentioned in Pro Git. > > Andy > > -- > To unsubscribe from this list: send the line "unsubscribe git" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html