topo-order: make --date-order optional.

This adds --date-order to rev-list; it is similar to topo order
in the sense that no parent comes before all of its children,
but otherwise things are still ordered in the commit timestamp
order.

The same flag is also added to show-branch.

Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Junio C Hamano
2006-02-15 22:05:33 -08:00
parent be97bd1b88
commit 4c8725f16a
5 changed files with 29 additions and 9 deletions

View File

@ -72,6 +72,8 @@ int count_parents(struct commit * commit);
* Post-conditions:
* invariant of resulting list is:
* a reachable from b => ord(b) < ord(a)
* in addition, when lifo == 0, commits on parallel tracks are
* sorted in the dates order.
*/
void sort_in_topological_order(struct commit_list ** list);
void sort_in_topological_order(struct commit_list ** list, int lifo);
#endif /* COMMIT_H */