git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: What's the definition of a valid Git symbolic reference?

From
Emeric Fermas <emeric.fermas@gmail.com>
Date
Feb 15, 2011, 03:49 UTC
Message-ID
<AANLkTi=FKXqu_psoT+gvyq2c_o8Mej+DgpccecOpQd8H@mail.gmail.com>
In-Reply-To
<F624322D-359A-48ED-A241-622042F77CDA@sb.org>
Thanks a lot for this answer.

I've also read the man page of check-ref-format. However, there may be some not up-to-date documentation or some "non guarded against" command usage in git.

This explains the second part of my question ("Or maybe this command (ie. check-ref-format) is not intended to deal with symbolic links ?").

Another possibility would be that only git internal symbolic references are allowed to live under the ".git" dir (HEAD, FETCH_HEAD, ...) and that user defined symrefs should live under refs/. In this case, maybe "git symbolic-ref" should also prevent the user from creating a reference which doesn't contains a forward slash.

Once again, by reading at the code I can understand how those commands currently work. What I'm trying to achieve is to understand what should be their recommended usage.

Of course, I'll be glad to contribute any code/doc patch once the "voice of the git community" has spoken :-)

Em.
On Tue, Feb 15, 2011 at 4:19 AM, Kevin Ballard <kevin@sb.org> wrote:
Show 14 quoted lines
> On Feb 14, 2011, at 12:58 PM, Emeric Fermas wrote:
>
>> - As check-ref-format fails when being passed "first", does this mean
>> that it's not recommended to create a symbolic reference at the same
>> level than "HEAD"? Or maybe this command is not intended to deal with
>> symbolic links ?
>
> I don't know about the rest of your question, but check-ref-format
> explicitly states in the manpage that the refname must have at least
> one /, to enforce the presence of a category (such as heads/) in the
> refname.
>
> -Kevin Ballard
>
Previous: Kevin BallardNext: Tomas Carnecky
Message 3 of 8 in “What's the definition of a valid Git symbolic reference?”
  1. Emeric FermasFeb 14, 2011
  2. Kevin BallardFeb 15, 2011
  3. Emeric FermasFeb 15, 2011
  4. Tomas CarneckyFeb 15, 2011
  5. Kevin P. FlemingFeb 19, 2011
  6. Junio C HamanoFeb 15, 2011
  7. Emeric FermasFeb 15, 2011
  8. Jeff KingFeb 15, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.