Re: git remote update -> rejected
- From
- Teemu Likonen <tlikonen@iki.fi>
- Date
- Apr 22, 2008, 14:04 UTC
- Message-ID
- <20080422140440.GC3098@mithlond.arda.local>
- In-Reply-To
- <alpine.DEB.1.00.0804221449240.4460@eeepc-johanness>
Johannes Schindelin wrote (2008-04-22 14:49 +0100):
Show 13 quoted lines
> On Tue, 22 Apr 2008, Teemu Likonen wrote: > > > Hmm, to me it looks like --mirror is for mirroring remote repository > > and hence the "+" makes sense in here too. It's like "I want to make > > my repository a copy of that remote repository" hence the name > > 'mirror'. It'll possibly overwrite local branches but in my way of > > thinking mirroring implies that possibility. The 'git remote' manual > > says that --mirror "only makes sense in bare repositories", so the > > manual seems to guide towards not having local working directory nor > > changes. > > Okay, how about this: take Peff's patch, but add a warning if --mirror > is used on a non-bare repository?
Sounds good to me. Indeed, giving a warning is _very_ good idea as --mirror is potentially, even likely, destructive with local changes and working directory.