Which characters are illegal within a branch name?

Which characters are illegal within a branch name?

  • Adapting svn:externals usage for move to Mercurial
  • Git add branch on one single directory?
  • Rolling back or re-creating the master branch in git?
  • how to identify branches that need to get merged in git
  • Why did git svn remote tracking stopped working?
  • Git: how to merge modified files only
  • Can't find the .pbxproj file in Xcode
  • Remove file from Version Control in IntelliJ IDEA
  • github desktop merge commit hiding comments
  • GIT XCODE4 - Authentication Error
  • fatal: ambiguous argument 'origin': unknown revision or path not in the working tree
  • What is the purpose of empty “remotes” folders in the .git folder?
  • One Solution collect form web for “Which characters are illegal within a branch name?”

    A branch name cannot:

    • Have a path component that begins with “.”
    • Have a double dot “..”
    • End with a “/”
    • End with “.lock”
    • Contain an ASCII control character, “~”, “^”, “:” or SP
    • Contain a “\” (backslash)
    • Contain whitespace

    Thanks to Jakub Narębski: the man page for git check-ref-format has more details.

    Git Baby is a git and github fan, let's start git clone.