aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/git-for-each-ref.txt
diff options
context:
space:
mode:
authorHariom Verma <hariom18599@gmail.com>2020-08-21 21:41:47 +0000
committerJunio C Hamano <gitster@pobox.com>2020-08-28 13:52:50 -0700
commit837adb102f6bfd6e05c75afc630f20c1c720cc74 (patch)
treebb39e8156d91da5f29273febbc1c29d861c6348c /Documentation/git-for-each-ref.txt
parent87d3beb6e0eedfb83a8dd425e3c612d977b6ac8d (diff)
downloadgit-837adb102f6bfd6e05c75afc630f20c1c720cc74.tar.gz
ref-filter: add `short` modifier to 'tree' atom
Sometimes while using 'tree' atom, user might want to see abbrev hash instead of full 40 character hash. Just like 'objectname', it might be convenient for users to have the `:short` and `:short=<length>` option for printing 'tree' hash. Let's introduce `short` option to 'tree' atom. Mentored-by: Christian Couder <chriscool@tuxfamily.org> Mentored-by: Heba Waly <heba.waly@gmail.com> Signed-off-by: Hariom Verma <hariom18599@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/git-for-each-ref.txt')
-rw-r--r--Documentation/git-for-each-ref.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/Documentation/git-for-each-ref.txt b/Documentation/git-for-each-ref.txt
index e6ce8af612..40ebdfcc41 100644
--- a/Documentation/git-for-each-ref.txt
+++ b/Documentation/git-for-each-ref.txt
@@ -222,6 +222,8 @@ worktreepath::
In addition to the above, for commit and tag objects, the header
field names (`tree`, `parent`, `object`, `type`, and `tag`) can
be used to specify the value in the header field.
+Field `tree` can also be used with modifier `:short` and
+`:short=<length>` just like `objectname`.
For commit and tag objects, the special `creatordate` and `creator`
fields will correspond to the appropriate date or name-email-date tuple