From: Junio C Hamano Date: Fri, 25 Apr 2008 05:40:02 +0000 (-0700) Subject: Merge branch 'maint' X-Git-Tag: v1.5.6-rc0~125 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/049a226fa14fb25c03d2146c2f8f184cfea5e5bf?ds=inline;hp=-c Merge branch 'maint' * maint: remote: create fetch config lines with '+' push: allow unqualified dest refspecs to DWIM doc/git-gc: add a note about what is collected t5516: remove ambiguity test (1) Linked glossary from cvs-migration page write-tree: properly detect failure to write tree objects --- 049a226fa14fb25c03d2146c2f8f184cfea5e5bf diff --combined builtin-remote.c index a3ee1ac393,4149f3b3ce..93bb84e1d4 --- a/builtin-remote.c +++ b/builtin-remote.c @@@ -19,8 -19,6 +19,8 @@@ static const char * const builtin_remot static int verbose; +static int show_all(void); + static inline int postfixcmp(const char *string, const char *postfix) { int len1 = strlen(string), len2 = strlen(postfix); @@@ -107,6 -105,7 +107,7 @@@ static int add(int argc, const char **a struct path_list_item *item = track.items + i; strbuf_reset(&buf2); + strbuf_addch(&buf2, '+'); if (mirror) strbuf_addf(&buf2, "refs/%s:refs/%s", item->path, item->path); @@@ -386,11 -385,8 +387,11 @@@ static int show_or_prune(int argc, cons argc = parse_options(argc, argv, options, builtin_remote_usage, 0); - if (argc < 1) + if (argc < 1) { + if (!prune) + return show_all(); usage_with_options(builtin_remote_usage, options); + } memset(&states, 0, sizeof(states)); for (; argc; argc--, argv++) {