diff options
author | Junio C Hamano <gitster@pobox.com> | 2008-07-08 15:25:44 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2008-07-08 15:25:44 -0700 |
commit | 8bb65883d164843d5bb7475281af09bae18ab22d (patch) | |
tree | 7cf44a14a8aa1981ba814129948a4ed5918d3f88 /builtin-rev-list.c | |
parent | a32a4eaa36527ab1c9a999357f9edd5e04591a4a (diff) | |
parent | 85af7929ee125385c2771fa4eaccfa2f29dc63c9 (diff) | |
download | git-8bb65883d164843d5bb7475281af09bae18ab22d.tar.gz git-8bb65883d164843d5bb7475281af09bae18ab22d.tar.xz |
Merge branch 'jc/blame' (early part) into HEAD
* 'jc/blame' (early part):
git-blame --reverse
builtin-blame.c: allow more than 16 parents
builtin-blame.c: move prepare_final() into a separate function.
rev-list --children
revision traversal: --children option
Conflicts:
Documentation/rev-list-options.txt
revision.c
Diffstat (limited to 'builtin-rev-list.c')
-rw-r--r-- | builtin-rev-list.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/builtin-rev-list.c b/builtin-rev-list.c index 83a7b1349..11a7eae55 100644 --- a/builtin-rev-list.c +++ b/builtin-rev-list.c @@ -37,6 +37,7 @@ static const char rev_list_usage[] = " --reverse\n" " formatting output:\n" " --parents\n" +" --children\n" " --objects | --objects-edge\n" " --unpacked\n" " --header | --pretty\n" @@ -90,6 +91,15 @@ static void show_commit(struct commit *commit) parents = parents->next; } } + if (revs.children.name) { + struct commit_list *children; + + children = lookup_decoration(&revs.children, &commit->object); + while (children) { + printf(" %s", sha1_to_hex(children->item->object.sha1)); + children = children->next; + } + } show_decorations(commit); if (revs.commit_format == CMIT_FMT_ONELINE) putchar(' '); |