]> git.ipfire.org Git - thirdparty/git.git/blobdiff - revision.c
Makefile: Include subdirectories in "make cover" reports
[thirdparty/git.git] / revision.c
index 7847921658c0f0b13c51650057b907ee431b1378..7e82efd9324e84582732485c53c6c25a24c29997 100644 (file)
@@ -1162,18 +1162,22 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
 
        if (!prefixcmp(arg, "--max-count=")) {
                revs->max_count = atoi(arg + 12);
+               revs->no_walk = 0;
        } else if (!prefixcmp(arg, "--skip=")) {
                revs->skip_count = atoi(arg + 7);
        } else if ((*arg == '-') && isdigit(arg[1])) {
        /* accept -<digit>, like traditional "head" */
                revs->max_count = atoi(arg + 1);
+               revs->no_walk = 0;
        } else if (!strcmp(arg, "-n")) {
                if (argc <= 1)
                        return error("-n requires an argument");
                revs->max_count = atoi(argv[1]);
+               revs->no_walk = 0;
                return 2;
        } else if (!prefixcmp(arg, "-n")) {
                revs->max_count = atoi(arg + 2);
+               revs->no_walk = 0;
        } else if (!prefixcmp(arg, "--max-age=")) {
                revs->max_age = atoi(arg + 10);
        } else if (!prefixcmp(arg, "--since=")) {
@@ -1249,6 +1253,8 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
                revs->boundary = 1;
        } else if (!strcmp(arg, "--left-right")) {
                revs->left_right = 1;
+       } else if (!strcmp(arg, "--count")) {
+               revs->count = 1;
        } else if (!strcmp(arg, "--cherry-pick")) {
                revs->cherry_pick = 1;
                revs->limited = 1;
@@ -1308,8 +1314,8 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
                else
                        strbuf_addstr(&buf, "refs/notes/");
                strbuf_addstr(&buf, arg+13);
-               string_list_append(strbuf_detach(&buf, NULL),
-                                  revs->notes_opt.extra_notes_refs);
+               string_list_append(revs->notes_opt.extra_notes_refs,
+                                  strbuf_detach(&buf, NULL));
        } else if (!strcmp(arg, "--no-notes")) {
                revs->show_notes = 0;
                revs->show_notes_given = 1;