Code

Merge branch 'jc/log-quiet-fix'
authorJunio C Hamano <gitster@pobox.com>
Tue, 31 May 2011 19:09:18 +0000 (12:09 -0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 31 May 2011 19:09:18 +0000 (12:09 -0700)
* jc/log-quiet-fix:
  log: --quiet should serve as synonym to -s

1  2 
builtin/log.c

diff --cc builtin/log.c
index 27849dc91de03a46d4c9357ca0d7b3f79188cc98,4b7f8f47f353dc3da942fb4348ab21a8b20620fb..224b16792042c5633a2f1820082b3ca18d81e5fd
@@@ -106,7 -88,22 +106,9 @@@ static void cmd_log_init_finish(int arg
                             PARSE_OPT_KEEP_ARGV0 | PARSE_OPT_KEEP_UNKNOWN |
                             PARSE_OPT_KEEP_DASHDASH);
  
 -      rev->abbrev = DEFAULT_ABBREV;
 -      rev->commit_format = CMIT_FMT_DEFAULT;
 -      if (fmt_pretty)
 -              get_commit_format(fmt_pretty, rev);
 -      rev->verbose_header = 1;
 -      DIFF_OPT_SET(&rev->diffopt, RECURSIVE);
 -      rev->show_root_diff = default_show_root;
 -      rev->subject_prefix = fmt_patch_subject_prefix;
 -      DIFF_OPT_SET(&rev->diffopt, ALLOW_TEXTCONV);
 -
 -      if (default_date_mode)
 -              rev->date_mode = parse_date_format(default_date_mode);
 -
        argc = setup_revisions(argc, argv, rev, opt);
+       if (quiet)
+               rev->diffopt.output_format |= DIFF_FORMAT_NO_OUTPUT;
  
        /* Any arguments at this point are not recognized */
        if (argc > 1)