* [PATCH] max-count in terms of intersection
@ 2005-11-20 15:53 Luben Tuikov
0 siblings, 0 replies; only message in thread
From: Luben Tuikov @ 2005-11-20 15:53 UTC (permalink / raw
To: git
When a path designation is given, max-count counts the number
of commits therein (intersection), not globally.
This avoids the case where in case path has been inactive
for the last N commits, --max-count=N and path designation
at git-rev-list is given, would give no commits.
Signed-off-by: Luben Tuikov <ltuikov@yahoo.com>
---
rev-list.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
applies-to: 5b820842ce0afb836ddbeded3a3f9e8d0ba223f9
768b79de9eadc38a839332df0fcce021f7174d6d
diff --git a/rev-list.c b/rev-list.c
index 6e6ffde..e17f928 100644
--- a/rev-list.c
+++ b/rev-list.c
@@ -124,8 +124,6 @@ static int filter_commit(struct commit *
stop_traversal=1;
return CONTINUE;
}
- if (max_count != -1 && !max_count--)
- return STOP;
if (no_merges && (commit->parents && commit->parents->next))
return CONTINUE;
if (paths && dense) {
@@ -148,6 +146,9 @@ static int process_commit(struct commit
return CONTINUE;
}
+ if (max_count != -1 && !max_count--)
+ return STOP;
+
show_commit(commit);
return CONTINUE;
---
0.99.9.GIT
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2005-11-20 15:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-20 15:53 [PATCH] max-count in terms of intersection Luben Tuikov
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).