diff options
author | Karthik Nayak <karthik.188@gmail.com> | 2017-01-10 14:19:41 +0530 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-01-10 12:44:31 -0800 |
commit | 7743fcca5be6854a1b9a5a0f7e60b79c15fee4b9 (patch) | |
tree | eea4617d10d7b555a1eabecb141fe67fc50f9cc9 /Documentation | |
parent | ffd921d311c9293ce83e0d191769a962d9197a71 (diff) | |
download | git-7743fcca5be6854a1b9a5a0f7e60b79c15fee4b9.tar.gz |
ref-filter: add support for %(upstream:track,nobracket)
Add support for %(upstream:track,nobracket) which will print the
tracking information without the brackets (i.e. "ahead N, behind M").
This is needed when we port branch.c to use ref-filter's printing APIs.
Add test and documentation for the same.
Mentored-by: Christian Couder <christian.couder@gmail.com>
Mentored-by: Matthieu Moy <matthieu.moy@grenoble-inp.fr>
Signed-off-by: Karthik Nayak <karthik.188@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/git-for-each-ref.txt | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/Documentation/git-for-each-ref.txt b/Documentation/git-for-each-ref.txt index 94c6b88faa..14240b4075 100644 --- a/Documentation/git-for-each-ref.txt +++ b/Documentation/git-for-each-ref.txt @@ -120,9 +120,13 @@ upstream:: `refname` above. Additionally respects `:track` to show "[ahead N, behind M]" and `:trackshort` to show the terse version: ">" (ahead), "<" (behind), "<>" (ahead and behind), - or "=" (in sync). Has no effect if the ref does not have - tracking information associated with it. `:track` also prints - "[gone]" whenever unknown upstream ref is encountered. + or "=" (in sync). `:track` also prints "[gone]" whenever + unknown upstream ref is encountered. Append `:track,nobracket` + to show tracking information without brackets (i.e "ahead N, + behind M"). Has no effect if the ref does not have tracking + information associated with it. All the options apart from + `nobracket` are mutually exclusive, but if used together the + last option is selected. push:: The name of a local ref which represents the `@{push}` location |