Skip to content

Commit

Permalink
Merge pull request #5581 from tk0miya/5557_quickstart_no_batchfile
Browse files Browse the repository at this point in the history
Fix #5557: quickstart: --no-batchfile isn't honored
  • Loading branch information
tk0miya committed Nov 1, 2018
2 parents 7a1516a + 0113090 commit 6686711
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ Bugs fixed
* #5563: latex: footnote_references generated by extension causes LaTeX builder
crashed
* #5561: make all-pdf fails with old xindy version
* #5557: quickstart: --no-batchfile isn't honored

Testing
--------
Expand Down
10 changes: 5 additions & 5 deletions sphinx/cmd/quickstart.py
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,7 @@ def get_parser():
"""))

parser.add_argument('-q', '--quiet', action='store_true', dest='quiet',
default=False,
default=None,
help=__('quiet mode'))
parser.add_argument('--version', action='version', dest='show_version',
version='%%(prog)s %s' % __display_version__)
Expand All @@ -552,7 +552,7 @@ def get_parser():
help=__('output path'))

group = parser.add_argument_group(__('Structure options'))
group.add_argument('--sep', action='store_true',
group.add_argument('--sep', action='store_true', default=None,
help=__('if specified, separate source and build dirs'))
group.add_argument('--dot', metavar='DOT',
help=__('replacement for dot in _templates etc.'))
Expand Down Expand Up @@ -584,11 +584,11 @@ def get_parser():
action='append', help=__('enable arbitrary extensions'))

group = parser.add_argument_group(__('Makefile and Batchfile creation'))
group.add_argument('--makefile', action='store_true', dest='makefile',
group.add_argument('--makefile', action='store_true', dest='makefile', default=None,
help=__('create makefile'))
group.add_argument('--no-makefile', action='store_false', dest='makefile',
help=__('do not create makefile'))
group.add_argument('--batchfile', action='store_true', dest='batchfile',
group.add_argument('--batchfile', action='store_true', dest='batchfile', default=None,
help=__('create batchfile'))
group.add_argument('--no-batchfile', action='store_false',
dest='batchfile',
Expand Down Expand Up @@ -628,7 +628,7 @@ def main(argv=sys.argv[1:]):

d = vars(args)
# delete None or False value
d = dict((k, v) for k, v in d.items() if not (v is None or v is False))
d = dict((k, v) for k, v in d.items() if v is not None)

try:
if 'quiet' in d:
Expand Down

0 comments on commit 6686711

Please sign in to comment.