@@ -111,7 +111,7 @@ def _run_os(*args):
111
111
"""
112
112
subprocess .check_call (args , stdout = sys .stdout , stderr = sys .stderr )
113
113
114
- def _sphinx_build (self , kind ):
114
+ def _sphinx_build (self , kind : str ):
115
115
"""
116
116
Call sphinx to build documentation.
117
117
@@ -284,23 +284,20 @@ def zip_html(self):
284
284
def main ():
285
285
cmds = [method for method in dir (DocBuilder ) if not method .startswith ("_" )]
286
286
287
- joined = "," .join (cmds )
288
- joined_epilog = f"Commands: { joined } "
289
-
290
- joined_cmds = ", " .join (cmds )
291
-
287
+ joined = "," .joined (cmds )
292
288
argparser = argparse .ArgumentParser (
293
- description = "pandas documentation builder" , epilog = joined_epilog ,
289
+ description = "pandas documentation builder" , epilog = f"Commands: { joined } " ,
294
290
)
295
291
292
+ joined = ", " .join (cmds )
296
293
argparser .add_argument (
297
- "command" , nargs = "?" , default = "html" , help = f"command to run: { joined_cmds } " ,
294
+ "command" , nargs = "?" , default = "html" , help = f"command to run: { joined } " ,
298
295
)
299
296
argparser .add_argument (
300
297
"--num-jobs" , type = int , default = 0 , help = "number of jobs used by sphinx-build"
301
298
)
302
299
argparser .add_argument (
303
- "--no-api" , default = False , action = "store_true" , help = "omit api and autosummary"
300
+ "--no-api" , default = False , help = "omit api and autosummary" , action = "store_true "
304
301
)
305
302
argparser .add_argument (
306
303
"--single" ,
@@ -321,7 +318,10 @@ def main():
321
318
action = "count" ,
322
319
dest = "verbosity" ,
323
320
default = 0 ,
324
- help = "increase verbosity (can be repeated), passed to the sphinx build command" ,
321
+ help = (
322
+ "increase verbosity (can be repeated), "
323
+ "passed to the sphinx build command"
324
+ ),
325
325
)
326
326
argparser .add_argument (
327
327
"--warnings-are-errors" ,
0 commit comments