summaryrefslogtreecommitdiffstats
path: root/main.py
diff options
context:
space:
mode:
authorDan Willemsen <dwillemsen@google.com>2015-08-31 15:45:06 -0700
committerDan Willemsen <dwillemsen@google.com>2015-09-01 12:23:56 -0700
commit9ff2ece6abc5d0d4a69c2f086209f107fd4f04be (patch)
tree1daabfe078e59b38ba0a1fdf9f6b0c83bcf7eba9 /main.py
parent2487cb7b2c41506c8ef900dba735876b01c67eab (diff)
downloadgit-repo-9ff2ece6abc5d0d4a69c2f086209f107fd4f04be.tar.gz
gitc: Improve help visibilityv1.12.28
This improves the visiblity of gitc-init if we can get the gitc config, and hides it otherwise. Change-Id: I82830b0b07c311e8c74397ba79eb4c361f8b6fb5
Diffstat (limited to 'main.py')
-rwxr-xr-xmain.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/main.py b/main.py
index adfaffb0..a5979a87 100755
--- a/main.py
+++ b/main.py
@@ -42,6 +42,7 @@ from git_command import git, GitCommand
42from git_config import init_ssh, close_ssh 42from git_config import init_ssh, close_ssh
43from command import InteractiveCommand 43from command import InteractiveCommand
44from command import MirrorSafeCommand 44from command import MirrorSafeCommand
45from command import RequiresGitcCommand
45from subcmds.version import Version 46from subcmds.version import Version
46from editor import Editor 47from editor import Editor
47from error import DownloadError 48from error import DownloadError
@@ -143,6 +144,11 @@ class _Repo(object):
143 file=sys.stderr) 144 file=sys.stderr)
144 return 1 145 return 1
145 146
147 if isinstance(cmd, RequiresGitcCommand) and not gitc_utils.get_gitc_manifest_dir():
148 print("fatal: '%s' requires GITC to be available" % name,
149 file=sys.stderr)
150 return 1
151
146 try: 152 try:
147 copts, cargs = cmd.OptionParser.parse_args(argv) 153 copts, cargs = cmd.OptionParser.parse_args(argv)
148 copts = cmd.ReadEnvironmentOptions(copts) 154 copts = cmd.ReadEnvironmentOptions(copts)