[Bug] Convert config to pathlib.Path (#2377)

This commit is contained in:
Mika Ayenson
2022-11-01 10:43:32 -04:00
committed by GitHub
parent 97c90aaf3c
commit 24b5e8a8b0
+2 -1
View File
@@ -44,7 +44,8 @@ def root(ctx, debug):
@root.command('create-rule')
@click.argument('path', type=Path)
@click.option('--config', '-c', type=click.Path(exists=True, dir_okay=False), help='Rule or config file')
@click.option('--config', '-c', type=click.Path(exists=True, dir_okay=False, path_type=Path),
help='Rule or config file')
@click.option('--required-only', is_flag=True, help='Only prompt for required fields')
@click.option('--rule-type', '-t', type=click.Choice(sorted(TOMLRuleContents.all_rule_types())),
help='Type of rule to create')