summaryrefslogtreecommitdiffstats
path: root/main.py
diff options
context:
space:
mode:
Diffstat (limited to 'main.py')
-rwxr-xr-xmain.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/main.py b/main.py
index 5c8ea85c..253f3112 100755
--- a/main.py
+++ b/main.py
@@ -185,9 +185,7 @@ class _Repo(object):
185 print('\nRun `repo help <command>` for command-specific details.') 185 print('\nRun `repo help <command>` for command-specific details.')
186 return 0 186 return 0
187 elif gopts.show_version: 187 elif gopts.show_version:
188 if name and name != 'help': 188 # Always allow global --version regardless of subcommand validity.
189 print('fatal: invalid usage of --version', file=sys.stderr)
190 return 1
191 name = 'version' 189 name = 'version'
192 elif not name: 190 elif not name:
193 # No subcommand specified, so show the help/subcommand. 191 # No subcommand specified, so show the help/subcommand.