@matheusbsbs / matheus-bagliano / commits / 5d2dcc423e
Fork 0

General --quiet improvements

'git reset' is missing --quiet, and 'git gc' is not using OPT__QUIET. Let's fix that. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Felipe Contreras committed Dec 2, 2009 at 23:28 UTC 5d2dcc423ec689ff4a6bcb83b00d5b43657b0c88
3 files changed +3 -3
Documentation/git-reset.txt
+1
@@ -62,6 +62,7 @@ This means that `git reset -p` is the opposite of `git add -p` (see
62 linkgit:git-add[1]).
63
64 -q::
65 +--quiet::
66 Be quiet, only report errors.
67
68 <commit>::
builtin-gc.c
+1 -1
@@ -180,12 +180,12 @@ int cmd_gc(int argc, const char **argv, const char *prefix)
180 char buf[80];
181
182 struct option builtin_gc_options[] = {
183 + OPT__QUIET(&quiet),
184 { OPTION_STRING, 0, "prune", &prune_expire, "date",
185 "prune unreferenced objects",
186 PARSE_OPT_OPTARG, NULL, (intptr_t)prune_expire },
187 OPT_BOOLEAN(0, "aggressive", &aggressive, "be more thorough (increased runtime)"),
188 OPT_BOOLEAN(0, "auto", &auto_gc, "enable auto-gc mode"),
188 - OPT_BOOLEAN('q', "quiet", &quiet, "suppress progress reports"),
189 OPT_END()
190 };
191
builtin-reset.c
+1 -2
@@ -202,6 +202,7 @@ int cmd_reset(int argc, const char **argv, const char *prefix)
202 struct commit *commit;
203 char *reflog_action, msg[1024];
204 const struct option options[] = {
205 + OPT__QUIET(&quiet),
206 OPT_SET_INT(0, "mixed", &reset_type,
207 "reset HEAD and index", MIXED),
208 OPT_SET_INT(0, "soft", &reset_type, "reset only HEAD", SOFT),
@@ -209,8 +210,6 @@ int cmd_reset(int argc, const char **argv, const char *prefix)
210 "reset HEAD, index and working tree", HARD),
211 OPT_SET_INT(0, "merge", &reset_type,
212 "reset HEAD, index and working tree", MERGE),
212 - OPT_BOOLEAN('q', NULL, &quiet,
213 - "disable showing new HEAD in hard reset and progress message"),
213 OPT_BOOLEAN('p', "patch", &patch_mode, "select hunks interactively"),
214 OPT_END()
215 };