diff options
author | Arcadiy Ivanov <arcadiy@ivanov.biz> | 2016-09-14 01:25:38 -0400 |
---|---|---|
committer | Arcadiy Ivanov <arcadiy@ivanov.biz> | 2016-09-14 01:28:34 -0400 |
commit | 1db59830c3871e72f0c6219e1a9a1cf71e44a161 (patch) | |
tree | 0a1e24b795b5826ac423d9bf620cf34c5b2278c6 /sphinx/quickstart.py | |
parent | f6ca0feedb8d94fca819b0dbdc32bdadd139a167 (diff) | |
download | sphinx-git-1db59830c3871e72f0c6219e1a9a1cf71e44a161.tar.gz |
Quickstart should return an error consistently on all error conditions
fixes #2955, connected to #2955
Diffstat (limited to 'sphinx/quickstart.py')
-rw-r--r-- | sphinx/quickstart.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sphinx/quickstart.py b/sphinx/quickstart.py index 4680fecd4..751f87bff 100644 --- a/sphinx/quickstart.py +++ b/sphinx/quickstart.py @@ -1646,7 +1646,7 @@ def main(argv=sys.argv): if not set(['project', 'author', 'version']).issubset(d): print('''"quiet" is specified, but any of "project", \ "author" or "version" is not specified.''') - return + return 1 if set(['quiet', 'project', 'author', 'version']).issubset(d): # quiet mode with all required params satisfied, use default @@ -1666,13 +1666,13 @@ def main(argv=sys.argv): ' files already exist.')) print('sphinx-quickstart only generate into a empty directory.' ' Please specify a new root path.') - return + return 1 else: ask_user(d) except (KeyboardInterrupt, EOFError): print() print('[Interrupted.]') - return + return 130 # 128 + SIGINT # decode values in d if value is a Python string literal for key, value in d.items(): |