Re: [BUG] git-new-workdir doesn't understand packed refs
- From
- Peter Baumann <waste.manager@gmx.de>
- Date
- Apr 18, 2007, 18:31 UTC
- Message-ID
- <20070418183156.GF5913@xp.machine.xx>
- In-Reply-To
- <7vlkgph7i0.fsf@assigned-by-dhcp.cox.net>
On Wed, Apr 18, 2007 at 11:17:43AM -0700, Junio C Hamano wrote:
Show 17 quoted lines
> Peter Baumann <waste.manager@gmx.de> writes: > > > On Wed, Apr 18, 2007 at 09:23:14AM -0700, Junio C Hamano wrote: > >> > >> Recursively dereferencing the symbolic link by hand to a limit > >> to avoid infinite recursion (error out when we reach the limit) > >> would be a more elaborate solution that probably is the right > >> thing to do. > >> > > I thought about the case where packed-refs is a symlink to another symlink > > and then decided that it's not worth to implement this because a workdir > > should be linked to a _repo_ and not another workdir. > > That's incredibly weak, as the initial motivation of this patch > is that you did not want to say "you should run gc only in the > _repo_ not in workdir". >
Yes. That's my motivation and it works right now
git init a <hack, hack, hack,> git commit -a
git-new-workdir a b # allowed git-new-workdir a c # allowed
git-new-workdir b d # NOT ALLOWED
The user should only create new work dirs which refere to the repo and not to another workdir.
But *iff* thats the only point for keeping my patch out I'll fix it, but not tonight. (Leaving now ...)
-Peter