git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/4] glossary: define committish (a.k.a. commit-ish)

From
RHRichard Hansen <rhansen@bbn.com>
Date
Jun 19, 2013, 19:16 UTC
Message-ID
<51C203A1.4000404@bbn.com>
In-Reply-To
<7vhagu10ql.fsf@alter.siamese.dyndns.org>
On 2013-06-19 13:14, Junio C Hamano wrote:
> <object-type>-ish does not have anything to do with a ref.  Even
> when an object is dangling in your object store without being
> reachable from any of your refs, it keeps its own "ish"-ness.

Ah, so your personal definition of "ref" matches my personal definition of "ref", and this definition doesn't match gitglossary(7). :)

Show 16 quoted lines
> 
> "ish"-ness is a property of the object itself.
> 
>  * A commit object has a single top-level tree, and when a command
>    wants a tree object, you can often pass it a commit (historically
>    some commands were more strict and refused to work on a commit
>    when they wanted a tree).  In other words, a commit can be used
>    in place for a tree.  A commit object is a tree-ish.
> 
>  * A tag object, when it points (recursively) at a commit object,
>    can often be used in place for a commit object.  Such a tag
>    object is a commit-ish.
> 
>  * A tag object, when it points (recursively) at a tree object, can
>    often be used in place for a tree object.  Such a tag object is a
>    tree-ish.  Note that such a tag object cannot be a commit-ish.

I agree with all of this; the issue is the definition of "ref" in gitglossary(7). That definition should be fixed. In the meantime, I'll rework the patch series to avoid using the word "ref" when defining committish and tree-ish.

-Richard
Previous: Junio C HamanoNext: Junio C Hamano
Message 15 of 24 in “documentation cleanups for <rev>^{<type>}”
  1. 0/4 documentation cleanups for <rev>^{<type>}Richard Hansen, Jun 19, 2013
  2. 1/4 glossary: add 'treeish' as a synonym for 'tree-ish'Richard Hansen, Jun 19, 2013
  3. Junio C HamanoJun 19, 2013
  4. Richard HansenJun 19, 2013
  5. Junio C HamanoJun 19, 2013
  6. Richard HansenJun 19, 2013
  7. 2/4 glossary: define committish (a.k.a. commit-ish)Richard Hansen, Jun 19, 2013
  8. Ramkumar RamachandraJun 19, 2013
  9. Richard HansenJun 19, 2013
  10. Ramkumar RamachandraJun 19, 2013
  11. Richard HansenJun 19, 2013
  12. Richard HansenJun 19, 2013
  13. Jonathan NiederJun 19, 2013
  14. Junio C HamanoJun 19, 2013
  15. Richard HansenJun 19, 2013
  16. Junio C HamanoJun 19, 2013
  17. Richard HansenJun 19, 2013
  18. Junio C HamanoJun 19, 2013
  19. Richard HansenJun 19, 2013
  20. Junio C HamanoJun 20, 2013
  21. Ramkumar RamachandraJun 20, 2013
  22. Ramkumar RamachandraJun 20, 2013
  23. 3/4 glossary: more precise definition of tree-ish (a.k.a. treeish)Richard Hansen, Jun 19, 2013
  24. 4/4 revisions.txt: fix and clarify <rev>^{<type>}Richard Hansen, Jun 19, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.