revision API: split parent rewriting and parent printing options

This change allows parent rewriting to be performed without causing
the log and rev-list commands to print the parents.

Signed-off-by: Adam Simpkins <adam@adamsimpkins.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Adam Simpkins
2008-05-04 03:36:52 -07:00
committed by Junio C Hamano
parent c697ad143b
commit 885cf80899
4 changed files with 9 additions and 7 deletions

View File

@ -231,7 +231,7 @@ void show_log(struct rev_info *opt)
putchar('>');
}
fputs(diff_unique_abbrev(commit->object.sha1, abbrev_commit), stdout);
if (opt->parents)
if (opt->print_parents)
show_parents(commit, abbrev_commit);
show_decorations(commit);
putchar(opt->diffopt.line_termination);
@ -271,7 +271,7 @@ void show_log(struct rev_info *opt)
}
fputs(diff_unique_abbrev(commit->object.sha1, abbrev_commit),
stdout);
if (opt->parents)
if (opt->print_parents)
show_parents(commit, abbrev_commit);
if (parent)
printf(" (from %s)",