fix message when calling sphinx-build without arguments

This commit is contained in:
Georg Brandl
2015-07-24 16:37:18 +02:00
parent 6b6d3dbea9
commit 21188120cc

View File

@@ -27,11 +27,6 @@ from sphinx.util.osutil import abspath, fs_encoding
from sphinx.util.pycompat import terminal_safe
def usage(argv, msg=None):
if msg:
print(msg, file=sys.stderr)
print(file=sys.stderr)
USAGE = """\
Sphinx v%s
Usage: %%prog [options] sourcedir outdir [filenames...]
@@ -150,7 +145,7 @@ def main(argv):
return 1
outdir = abspath(args[1])
except IndexError:
usage(argv, 'Error: Insufficient arguments.')
parser.print_help()
return 1
except UnicodeError:
print(