Skip to content

Commit a0a7e9e

Browse files
committed
check-ref-format doc: de-emphasize the implementation detail of a ref
It is an unimportant implementation detail that branches and tags are stored somewhere under $GIT_DIR/refs directory. What is more important is that branches live in refs/heads and tags live in refs/tags hierarchy in the ref namespace. Signed-off-by: Junio C Hamano <[email protected]>
1 parent 0aceb22 commit a0a7e9e

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

Documentation/git-check-ref-format.txt

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,12 @@ Checks if a given 'refname' is acceptable, and exits with a non-zero
1818
status if it is not.
1919

2020
A reference is used in git to specify branches and tags. A
21-
branch head is stored under the `$GIT_DIR/refs/heads` directory, and
22-
a tag is stored under the `$GIT_DIR/refs/tags` directory (or, if refs
23-
are packed by `git gc`, as entries in the `$GIT_DIR/packed-refs` file).
21+
branch head is stored in the `refs/heads` hierarchy, while
22+
a tag is stored in the `refs/tags` hierarchy of the ref namespace
23+
(typically in `$GIT_DIR/refs/heads` and `$GIT_DIR/refs/tags`
24+
directories or, as entries in file `$GIT_DIR/packed-refs`
25+
if refs are packed by `git gc`).
26+
2427
git imposes the following rules on how references are named:
2528

2629
. They can include slash `/` for hierarchical (directory)

0 commit comments

Comments
 (0)