Skip to content

Commit 2b1f424

Browse files
spearceJunio C Hamano
authored andcommitted
Reference git-check-ref-format in git-branch.
Its nice to have git-check-ref-format actually get mentioned in git-branch's documentation as the syntax of a ref name must conform to what is described in git-check-ref-format. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
1 parent 8824689 commit 2b1f424

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

Documentation/git-branch.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ OPTIONS
4343

4444
<branchname>::
4545
The name of the branch to create or delete.
46+
The new branch name must pass all checks defined by
47+
gitlink:git-check-ref-format[1]. Some of these checks
48+
may restrict the characters allowed in a branch name.
4649

4750
<start-point>::
4851
The new branch will be created with a HEAD equal to this. It may

Documentation/git-checkout.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,10 @@ OPTIONS
3535
Force a re-read of everything.
3636

3737
-b::
38-
Create a new branch and start it at <branch>.
38+
Create a new branch named <new_branch> and start it at
39+
<branch>. The new branch name must pass all checks defined
40+
by gitlink:git-check-ref-format[1]. Some of these checks
41+
may restrict the characters allowed in a branch name.
3942

4043
-m::
4144
If you have local modifications to one or more files that

0 commit comments

Comments
 (0)