mirror of
https://github.com/ansible/ansible.git
synced 2026-08-04 16:13:32 +02:00
Turn pathlib paths into strs
Some APIs do not take a pathlib. They need to have a string representation of a path. Transform the default path to a str so those APIs will work with the default value.
This commit is contained in:
@@ -42,7 +42,7 @@ class DocumentCollectionMeta(Command):
|
||||
default=DEFAULT_TEMPLATE_FILE,
|
||||
help="Jinja2 template to use for the config")
|
||||
parser.add_argument("-T", "--template-dir", action="store", dest="template_dir",
|
||||
default=DEFAULT_TEMPLATE_DIR,
|
||||
default=str(DEFAULT_TEMPLATE_DIR),
|
||||
help="directory containing Jinja2 templates")
|
||||
parser.add_argument("-o", "--output-dir", action="store", dest="output_dir", default='/tmp/',
|
||||
help="Output directory for rst files")
|
||||
|
||||
@@ -46,7 +46,7 @@ class DocumentConfig(Command):
|
||||
default=DEFAULT_TEMPLATE_FILE,
|
||||
help="Jinja2 template to use for the config")
|
||||
parser.add_argument("-T", "--template-dir", action="store", dest="template_dir",
|
||||
default=DEFAULT_TEMPLATE_DIR,
|
||||
default=str(DEFAULT_TEMPLATE_DIR),
|
||||
help="directory containing Jinja2 templates")
|
||||
parser.add_argument("-o", "--output-dir", action="store", dest="output_dir", default='/tmp/',
|
||||
help="Output directory for rst files")
|
||||
|
||||
Reference in New Issue
Block a user