What's the recommended usage of a Git symbolic reference?

前端 未结 3 1048
自闭症患者
自闭症患者 2021-01-01 14:03

The following shell code correctly creates a chain of symbolic references

git symbolic-ref \"first\" \"refs/heads/master\"
git symbolic-ref \"second\" \"firs         


        
3条回答
  •  既然无缘
    2021-01-01 14:38

    Normally, symrefs live under refs/ — at least, this is what the git suite does (for example when using git filter-tree, you get refs/original/...). Some tools may choose to ignore refs that do not have the refs/ prefix.

    $ git symbolic-ref refs/first refs/heads/master
    $ git check-ref-format --print refs/first
    refs/first
    

提交回复
热议问题