Re: Deleting remote branch pointed by remote HEAD

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

 



On Wed, Jan 21, 2009 at 01:30:10PM -0500, Daniel Barkalow wrote:

> The information is available already; the only thing is that we don't have 
> a way to know that the user wants to get the remote's suggested HEAD; as 
> Junio pointed out at the time, a user might decide that "next" is the most 
> interesting branch, and set refs/remotes/origin/HEAD to that branch, and 
> therefore doesn't want it reset to the remote server's value.
> 
> That is, refs/remotes/origin/HEAD is only there to let the user abbreviate 
> the most useful branch of the remote; there's no reason it should reflect 
> the remote's HEAD, except that the remote's HEAD is a good guess if the 
> user hasn't said anything.

Good point. It is probably wrong to just fetch it without asking, then.

> I think it might be more appropriate to just care less about a broken 
> symref, explain what's wrong if the user actually tries to use it, and 
> otherwise mostly ignore it.

I thought about that, but I still wonder if deleting it when the
pointed-to ref is deleted might be more convenient. Remember that
"refs/remotes/$foo/HEAD" can be accessed by a shorthand "$foo". So that
means it can impact ref ambiguity lookup. I guess the chance of that
happening is fairly unlikely, though.

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

  Powered by Linux