summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a95148d)
raw | patch | inline | side by side (parent: a95148d)
author | Kjetil Barvik <barvik@broadpark.no> | |
Wed, 4 Mar 2009 17:47:39 +0000 (18:47 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Thu, 5 Mar 2009 04:36:24 +0000 (20:36 -0800) |
stat_tracking_info() in remote.c is used to collect the statistics to
be able to say (for instance) from the output of "git checkout':
Your branch and 'foo' have diverged,
and have X and Y different commit(s) each, respectively.
Currently X and Y also includes the count of merges. This patch
excludes the merges from being counted.
Signed-off-by: Kjetil Barvik <barvik@broadpark.no>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
be able to say (for instance) from the output of "git checkout':
Your branch and 'foo' have diverged,
and have X and Y different commit(s) each, respectively.
Currently X and Y also includes the count of merges. This patch
excludes the merges from being counted.
Signed-off-by: Kjetil Barvik <barvik@broadpark.no>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
remote.c | patch | blob | history |
diff --git a/remote.c b/remote.c
index d7079c6dd871dc1b482d347d013438fe30cc0908..06c414e11872c1c3c927ae6c70d55db6c0340724 100644 (file)
--- a/remote.c
+++ b/remote.c
@@ -1310,9 +1310,10 @@ int stat_tracking_info(struct branch *branch, int *num_ours, int *num_theirs)
if (theirs == ours)
return 0;
- /* Run "rev-list --left-right ours...theirs" internally... */
+ /* Run "rev-list --no-merges --left-right ours...theirs" internally... */
rev_argc = 0;
rev_argv[rev_argc++] = NULL;
+ rev_argv[rev_argc++] = "--no-merges";
rev_argv[rev_argc++] = "--left-right";
rev_argv[rev_argc++] = symmetric;
rev_argv[rev_argc++] = "--";