Re: [PATCH] cg-pull to stop treating "master" specially, fix fetch_local for .git/HEAD
- From
- Josef Weidendorfer <josef.weidendorfer@gmx.de>
- Date
- Nov 11, 2005, 01:13 UTC
- Message-ID
- <200511110213.54846.Josef.Weidendorfer@gmx.de>
- In-Reply-To
- <1131668075.3987.5.camel@dv>
On Friday 11 November 2005 01:14, Pavel Roskin wrote:
Show 11 quoted lines
> On Fri, 2005-11-11 at 00:40 +0100, Petr Baudis wrote: > > Dear diary, on Fri, Nov 11, 2005 at 12:26:18AM CET, I got a letter > > where Josef Weidendorfer <Josef.Weidendorfer@gmx.de> said that... > > > Why would anybody want to fetch the current upstream HEAD at cg-pull > > > time? > ... > Correct. But if it's a concern, I think we could make some > improvements. Following approaches could be tried (starting from top, > using following steps as a fallback): > > 1) Use recorded branch, i.e. the branch name that was used in cg-clone.
This is the "#..." part in .git/branches/origin, and it is already used.
I have nothing against using HEAD for cloning, but the branch name should be recorded, such that cg-pull always fetches from the same branch.
I think 1) is enough if we add the detected branch name in the #... part in .git/branches/origin at cg-clone time.
And "detectable" covers the local case, which was my concern here [*1*]
Josef
[*1*] after being told about the "stable HEAD" property of public repositories, which is correct. I am not even sure that a HEAD makes sense in public repositories: in my opinion HEAD has something to do with checked out files, and a public repository usually does not have these. But perhaps that's only me...