mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
- remove default=None with argparse is redundant since it's the
default value already. - use the argparse.ArgumentDefaultsHelpFormatter as the formatter_class, to print out automatically the default values
This commit is contained in:
parent
71a5ba3283
commit
4bac1ee745
3 changed files with 13 additions and 9 deletions
|
|
@ -234,7 +234,8 @@ def fields2pelican(fields, out_markup, output_path, dircat=False):
|
|||
def main():
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Transform feed, Wordpress or Dotclear files to rst files."
|
||||
"Be sure to have pandoc installed")
|
||||
"Be sure to have pandoc installed",
|
||||
formatter_class=argparse.ArgumentDefaultsHelpFormatter)
|
||||
|
||||
parser.add_argument(dest='input', help='The input file to read')
|
||||
parser.add_argument('--wpfile', action='store_true', dest='wpfile',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue