Skip to content

Commit

Permalink
Merge branch 'jk/remote-default-show'
Browse files Browse the repository at this point in the history
* jk/remote-default-show:
  git-remote: show all remotes with "git remote show"
  • Loading branch information
Junio C Hamano committed Apr 20, 2008
2 parents dc46fa3 + c4112bb commit 141ca95
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion builtin-remote.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ static const char * const builtin_remote_usage[] = {

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);
Expand Down Expand Up @@ -384,8 +386,11 @@ static int show_or_prune(int argc, const char **argv, int prune)

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++) {
Expand Down

0 comments on commit 141ca95

Please sign in to comment.