From 24b5e8a8b0fcc1258b6b2c197f2d8bcdfeb9adc1 Mon Sep 17 00:00:00 2001 From: Mika Ayenson Date: Tue, 1 Nov 2022 10:43:32 -0400 Subject: [PATCH] [Bug] Convert config to pathlib.Path (#2377) --- detection_rules/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/detection_rules/main.py b/detection_rules/main.py index baa1a68d9..628ccdf58 100644 --- a/detection_rules/main.py +++ b/detection_rules/main.py @@ -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')