Skip to content

Commit 89dde78

Browse files
committed
Merge branch 'rh/ishes-doc'
We liberally use "committish" and "commit-ish" (and "treeish" and "tree-ish"); as these are non-words, let's unify these terms to their dashed form. More importantly, clarify the documentation on object peeling using these terms. * rh/ishes-doc: glossary: fix and clarify the definition of 'ref' revisions.txt: fix and clarify <rev>^{<type>} glossary: more precise definition of tree-ish (a.k.a. treeish) use 'commit-ish' instead of 'committish' use 'tree-ish' instead of 'treeish' glossary: define commit-ish (a.k.a. committish) glossary: mention 'treeish' as an alternative to 'tree-ish'
2 parents cd8c891 + 4b6acde commit 89dde78

30 files changed

+118
-83
lines changed

Documentation/RelNotes/1.7.11.2.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Fixes since v1.7.11.1
3131
* "git diff --no-index" did not work with pagers correctly.
3232

3333
* "git diff COPYING HEAD:COPYING" gave a nonsense error message that
34-
claimed that the treeish HEAD did not have COPYING in it.
34+
claimed that the tree-ish HEAD did not have COPYING in it.
3535

3636
* When "git log" gets "--simplify-merges/by-decoration" together with
3737
"--first-parent", the combination of these options makes the

Documentation/config.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,8 @@ advice.*::
170170
pushNeedsForce::
171171
Shown when linkgit:git-push[1] rejects an update that
172172
tries to overwrite a remote ref that points at an
173-
object that is not a committish, or make the remote
174-
ref point at an object that is not a committish.
173+
object that is not a commit-ish, or make the remote
174+
ref point at an object that is not a commit-ish.
175175
statusHints::
176176
Show directions on how to proceed from the current
177177
state in the output of linkgit:git-status[1], in

Documentation/git-cat-file.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ OPTIONS
5454

5555
--textconv::
5656
Show the content as transformed by a textconv filter. In this case,
57-
<object> has be of the form <treeish>:<path>, or :<path> in order
57+
<object> has be of the form <tree-ish>:<path>, or :<path> in order
5858
to apply the filter to the content recorded in the index at <path>.
5959

6060
--batch::

Documentation/git-describe.txt

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ git-describe - Show the most recent tag that is reachable from a commit
99
SYNOPSIS
1010
--------
1111
[verse]
12-
'git describe' [--all] [--tags] [--contains] [--abbrev=<n>] <committish>...
12+
'git describe' [--all] [--tags] [--contains] [--abbrev=<n>] <commit-ish>...
1313
'git describe' [--all] [--tags] [--contains] [--abbrev=<n>] --dirty[=<mark>]
1414

1515
DESCRIPTION
@@ -26,8 +26,8 @@ see the -a and -s options to linkgit:git-tag[1].
2626

2727
OPTIONS
2828
-------
29-
<committish>...::
30-
Committish object names to describe.
29+
<commit-ish>...::
30+
Commit-ish object names to describe.
3131

3232
--dirty[=<mark>]::
3333
Describe the working tree.
@@ -57,7 +57,7 @@ OPTIONS
5757

5858
--candidates=<n>::
5959
Instead of considering only the 10 most recent tags as
60-
candidates to describe the input committish consider
60+
candidates to describe the input commit-ish consider
6161
up to <n> candidates. Increasing <n> above 10 will take
6262
slightly longer but may produce a more accurate result.
6363
An <n> of 0 will cause only exact matches to be output.
@@ -145,7 +145,7 @@ be sufficient to disambiguate these commits.
145145
SEARCH STRATEGY
146146
---------------
147147

148-
For each committish supplied, 'git describe' will first look for
148+
For each commit-ish supplied, 'git describe' will first look for
149149
a tag which tags exactly that commit. Annotated tags will always
150150
be preferred over lightweight tags, and tags with newer dates will
151151
always be preferred over tags with older dates. If an exact match
@@ -154,12 +154,12 @@ is found, its name will be output and searching will stop.
154154
If an exact match was not found, 'git describe' will walk back
155155
through the commit history to locate an ancestor commit which
156156
has been tagged. The ancestor's tag will be output along with an
157-
abbreviation of the input committish's SHA-1. If '--first-parent' was
157+
abbreviation of the input commit-ish's SHA-1. If '--first-parent' was
158158
specified then the walk will only consider the first parent of each
159159
commit.
160160

161161
If multiple tags were found during the walk then the tag which
162-
has the fewest commits different from the input committish will be
162+
has the fewest commits different from the input commit-ish will be
163163
selected and output. Here fewest commits different is defined as
164164
the number of commits which would be shown by `git log tag..input`
165165
will be the smallest number of commits possible.

Documentation/git-fast-import.txt

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -380,8 +380,8 @@ change to the project.
380380
('author' (SP <name>)? SP LT <email> GT SP <when> LF)?
381381
'committer' (SP <name>)? SP LT <email> GT SP <when> LF
382382
data
383-
('from' SP <committish> LF)?
384-
('merge' SP <committish> LF)?
383+
('from' SP <commit-ish> LF)?
384+
('merge' SP <commit-ish> LF)?
385385
(filemodify | filedelete | filecopy | filerename | filedeleteall | notemodify)*
386386
LF?
387387
....
@@ -460,9 +460,9 @@ as the current commit on that branch is automatically assumed to
460460
be the first ancestor of the new commit.
461461

462462
As `LF` is not valid in a Git refname or SHA-1 expression, no
463-
quoting or escaping syntax is supported within `<committish>`.
463+
quoting or escaping syntax is supported within `<commit-ish>`.
464464

465-
Here `<committish>` is any of the following:
465+
Here `<commit-ish>` is any of the following:
466466

467467
* The name of an existing branch already in fast-import's internal branch
468468
table. If fast-import doesn't know the name, it's treated as a SHA-1
@@ -509,7 +509,7 @@ additional ancestors (forming a 16-way merge). For this reason
509509
it is suggested that frontends do not use more than 15 `merge`
510510
commands per commit; 16, if starting a new, empty branch.
511511

512-
Here `<committish>` is any of the commit specification expressions
512+
Here `<commit-ish>` is any of the commit specification expressions
513513
also accepted by `from` (see above).
514514

515515
`filemodify`
@@ -677,8 +677,8 @@ paths for a commit are encouraged to do so.
677677
`notemodify`
678678
^^^^^^^^^^^^
679679
Included in a `commit` `<notes_ref>` command to add a new note
680-
annotating a `<committish>` or change this annotation contents.
681-
Internally it is similar to filemodify 100644 on `<committish>`
680+
annotating a `<commit-ish>` or change this annotation contents.
681+
Internally it is similar to filemodify 100644 on `<commit-ish>`
682682
path (maybe split into subdirectories). It's not advised to
683683
use any other commands to write to the `<notes_ref>` tree except
684684
`filedeleteall` to delete all existing notes in this tree.
@@ -691,7 +691,7 @@ External data format::
691691
commit that is to be annotated.
692692
+
693693
....
694-
'N' SP <dataref> SP <committish> LF
694+
'N' SP <dataref> SP <commit-ish> LF
695695
....
696696
+
697697
Here `<dataref>` can be either a mark reference (`:<idnum>`)
@@ -704,13 +704,13 @@ Inline data format::
704704
command.
705705
+
706706
....
707-
'N' SP 'inline' SP <committish> LF
707+
'N' SP 'inline' SP <commit-ish> LF
708708
data
709709
....
710710
+
711711
See below for a detailed description of the `data` command.
712712

713-
In both formats `<committish>` is any of the commit specification
713+
In both formats `<commit-ish>` is any of the commit specification
714714
expressions also accepted by `from` (see above).
715715

716716
`mark`
@@ -741,7 +741,7 @@ lightweight (non-annotated) tags see the `reset` command below.
741741

742742
....
743743
'tag' SP <name> LF
744-
'from' SP <committish> LF
744+
'from' SP <commit-ish> LF
745745
'tagger' (SP <name>)? SP LT <email> GT SP <when> LF
746746
data
747747
....
@@ -786,11 +786,11 @@ branch from an existing commit without creating a new commit.
786786

787787
....
788788
'reset' SP <ref> LF
789-
('from' SP <committish> LF)?
789+
('from' SP <commit-ish> LF)?
790790
LF?
791791
....
792792

793-
For a detailed description of `<ref>` and `<committish>` see above
793+
For a detailed description of `<ref>` and `<commit-ish>` see above
794794
under `commit` and `from`.
795795

796796
The `LF` after the command is optional (it used to be required).

Documentation/git-merge-tree.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ SYNOPSIS
1313

1414
DESCRIPTION
1515
-----------
16-
Reads three treeish, and output trivial merge results and
16+
Reads three tree-ish, and output trivial merge results and
1717
conflicting stages to the standard output. This is similar to
1818
what three-way 'git read-tree -m' does, but instead of storing the
1919
results in the index, the command outputs the entries to the

Documentation/git-name-rev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ SYNOPSIS
1010
--------
1111
[verse]
1212
'git name-rev' [--tags] [--refs=<pattern>]
13-
( --all | --stdin | <committish>... )
13+
( --all | --stdin | <commit-ish>... )
1414

1515
DESCRIPTION
1616
-----------

Documentation/git-push.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ already exists on the remote side.
121121
--follow-tags::
122122
Push all the refs that would be pushed without this option,
123123
and also push annotated tags in `refs/tags` that are missing
124-
from the remote but are pointing at committish that are
124+
from the remote but are pointing at commit-ish that are
125125
reachable from the refs being pushed.
126126

127127
--receive-pack=<git-receive-pack>::

Documentation/gitcli.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ couple of magic command line options:
106106
+
107107
---------------------------------------------
108108
$ git describe -h
109-
usage: git describe [options] <committish>*
109+
usage: git describe [options] <commit-ish>*
110110
or: git describe [options] --dirty
111111

112112
--contains find the tag that comes after the commit

Documentation/glossary-content.txt

Lines changed: 39 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,18 @@ to point at the new commit.
8282
to the top <<def_directory,directory>> of the stored
8383
revision.
8484

85+
[[def_commit-ish]]commit-ish (also committish)::
86+
A <<def_commit_object,commit object>> or an
87+
<<def_object,object>> that can be recursively dereferenced to
88+
a commit object.
89+
The following are all commit-ishes:
90+
a commit object,
91+
a <<def_tag_object,tag object>> that points to a commit
92+
object,
93+
a tag object that points to a tag object that points to a
94+
commit object,
95+
etc.
96+
8597
[[def_core_git]]core Git::
8698
Fundamental data structures and utilities of Git. Exposes only limited
8799
source code management tools.
@@ -427,10 +439,20 @@ should not be combined with other pathspec.
427439
to the result.
428440

429441
[[def_ref]]ref::
430-
A 40-byte hex representation of a <<def_SHA1,SHA-1>> or a name that
431-
denotes a particular <<def_object,object>>. They may be stored in
432-
a file under `$GIT_DIR/refs/` directory, or
433-
in the `$GIT_DIR/packed-refs` file.
442+
A name that begins with `refs/` (e.g. `refs/heads/master`)
443+
that points to an <<def_object_name,object name>> or another
444+
ref (the latter is called a <<def_symref,symbolic ref>>).
445+
For convenience, a ref can sometimes be abbreviated when used
446+
as an argument to a Git command; see linkgit:gitrevisions[7]
447+
for details.
448+
Refs are stored in the <<def_repository,repository>>.
449+
+
450+
The ref namespace is hierarchical.
451+
Different subhierarchies are used for different purposes (e.g. the
452+
`refs/heads/` hierarchy is used to represent local branches).
453+
+
454+
There are a few special-purpose refs that do not begin with `refs/`.
455+
The most notable example is `HEAD`.
434456

435457
[[def_reflog]]reflog::
436458
A reflog shows the local "history" of a ref. In other words,
@@ -530,10 +552,19 @@ should not be combined with other pathspec.
530552
with refs to the associated blob and/or tree objects. A
531553
<<def_tree,tree>> is equivalent to a <<def_directory,directory>>.
532554

533-
[[def_tree-ish]]tree-ish::
534-
A <<def_ref,ref>> pointing to either a <<def_commit_object,commit
535-
object>>, a <<def_tree_object,tree object>>, or a <<def_tag_object,tag
536-
object>> pointing to a tag or commit or tree object.
555+
[[def_tree-ish]]tree-ish (also treeish)::
556+
A <<def_tree_object,tree object>> or an <<def_object,object>>
557+
that can be recursively dereferenced to a tree object.
558+
Dereferencing a <<def_commit_object,commit object>> yields the
559+
tree object corresponding to the <<def_revision,revision>>'s
560+
top <<def_directory,directory>>.
561+
The following are all tree-ishes:
562+
a <<def_commit-ish,commit-ish>>,
563+
a tree object,
564+
a <<def_tag_object,tag object>> that points to a tree object,
565+
a tag object that points to a tag object that points to a tree
566+
object,
567+
etc.
537568

538569
[[def_unmerged_index]]unmerged index::
539570
An <<def_index,index>> which contains unmerged

0 commit comments

Comments
 (0)