diff options
author | Mike Frysinger <vapier@google.com> | 2021-04-13 14:57:40 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@google.com> | 2021-04-13 22:25:17 +0000 |
commit | 9180a07b8fb33d5ba0b82facf987b51ca7b15dc4 (patch) | |
tree | 4c815bea7136115bf382a1bb75b89b67bd39bd61 /subcmds/init.py | |
parent | f32f243ff8aaabe5287235015e1ce189da0123e3 (diff) | |
download | git-repo-9180a07b8fb33d5ba0b82facf987b51ca7b15dc4.tar.gz |
command: make --verbose/--quiet available to all subcommands
Add new CommonOptions entry points to move the existing --jobs to,
and relocate all --verbose/--quiet options to that. This provides
both a consistent interface for users as well as for code.
Change-Id: Ifaf83b88872421f4749b073c472b4a67ca6c0437
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/303224
Reviewed-by: Raman Tenneti <rtenneti@google.com>
Tested-by: Mike Frysinger <vapier@google.com>
Diffstat (limited to 'subcmds/init.py')
-rw-r--r-- | subcmds/init.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/subcmds/init.py b/subcmds/init.py index a23e529d..4182262e 100644 --- a/subcmds/init.py +++ b/subcmds/init.py | |||
@@ -79,6 +79,9 @@ manifest, a subsequent `repo sync` (or `repo sync -d`) is necessary | |||
79 | to update the working directory files. | 79 | to update the working directory files. |
80 | """ | 80 | """ |
81 | 81 | ||
82 | def _CommonOptions(self, p): | ||
83 | """Disable due to re-use of Wrapper().""" | ||
84 | |||
82 | def _Options(self, p, gitc_init=False): | 85 | def _Options(self, p, gitc_init=False): |
83 | Wrapper().InitParser(p, gitc_init=gitc_init) | 86 | Wrapper().InitParser(p, gitc_init=gitc_init) |
84 | 87 | ||
@@ -436,9 +439,6 @@ to update the working directory files. | |||
436 | % ('.'.join(str(x) for x in MIN_GIT_VERSION_SOFT),), | 439 | % ('.'.join(str(x) for x in MIN_GIT_VERSION_SOFT),), |
437 | file=sys.stderr) | 440 | file=sys.stderr) |
438 | 441 | ||
439 | opt.quiet = opt.output_mode is False | ||
440 | opt.verbose = opt.output_mode is True | ||
441 | |||
442 | rp = self.manifest.repoProject | 442 | rp = self.manifest.repoProject |
443 | 443 | ||
444 | # Handle new --repo-url requests. | 444 | # Handle new --repo-url requests. |