[PATCH v1] git rev-list doesn't complain when repo is empty
From: Atousa Pahlevan Duprat <apahlevan@ieee.org>
Signed-off-by: Atousa Pahlevan Duprat <apahlevan@ieee.org>
---
builtin/rev-list.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/builtin/rev-list.c b/builtin/rev-list.c
index d80d1ed..f71b87f 100644
--- a/builtin/rev-list.c
+++ b/builtin/rev-list.c
@@ -348,7 +348,7 @@ int cmd_rev_list(int argc, const char **argv, const char *prefix)
(!(revs.tag_objects || revs.tree_objects || revs.blob_objects) &&
!revs.pending.nr)) ||
revs.diff)
- usage(rev_list_usage);
+ return 0; // empty repo
if (revs.show_notes)
die(_("rev-list does not support display of notes"));
--
2.4.9 (Apple Git-60)