summaryrefslogtreecommitdiff
path: root/rev-list.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2005-07-03 20:29:54 (GMT)
committerLinus Torvalds <torvalds@g5.osdl.org>2005-07-03 20:29:54 (GMT)
commit12d2a18780321e0d00a0656f4965716ada910f66 (patch)
tree934ae85a8bf68bd3488080d6498b419b31660b82 /rev-list.c
parenteb019375abf545ec644e043f830ab573c2a4cd74 (diff)
downloadgit-12d2a18780321e0d00a0656f4965716ada910f66.zip
git-12d2a18780321e0d00a0656f4965716ada910f66.tar.gz
git-12d2a18780321e0d00a0656f4965716ada910f66.tar.bz2
"git rev-list --unpacked" shows only unpacked commits
More infrastructure to do efficient incremental packs.
Diffstat (limited to 'rev-list.c')
-rw-r--r--rev-list.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/rev-list.c b/rev-list.c
index abb611f..d836feb 100644
--- a/rev-list.c
+++ b/rev-list.c
@@ -15,10 +15,14 @@ static const char rev_list_usage[] =
" --max-count=nr\n"
" --max-age=epoch\n"
" --min-age=epoch\n"
+ " --bisect\n"
+ " --objects\n"
+ " --unpacked\n"
" --header\n"
" --pretty\n"
" --merge-order [ --show-breaks ]";
+static int unpacked = 0;
static int bisect_list = 0;
static int tag_objects = 0;
static int tree_objects = 0;
@@ -318,6 +322,8 @@ static struct commit_list *limit_list(struct commit_list *list)
struct commit *commit = pop_most_recent_commit(&list, SEEN);
struct object *obj = &commit->object;
+ if (unpacked && has_sha1_pack(obj->sha1))
+ obj->flags |= UNINTERESTING;
if (obj->flags & UNINTERESTING) {
mark_parents_uninteresting(commit);
if (everybody_uninteresting(list))
@@ -450,6 +456,11 @@ int main(int argc, char **argv)
blob_objects = 1;
continue;
}
+ if (!strcmp(arg, "--unpacked")) {
+ unpacked = 1;
+ limited = 1;
+ continue;
+ }
if (!strncmp(arg, "--merge-order", 13)) {
merge_order = 1;
continue;