From 37fddb87f7e82e2011bdc20120912abc315a697f Mon Sep 17 00:00:00 2001 From: Klaus Zerwes Date: Mon, 8 Aug 2022 20:56:47 +0200 Subject: [PATCH] implemented --do-not-use-default-exclude --- fqcn-fixer.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/fqcn-fixer.py b/fqcn-fixer.py index bae8cb0..95c8b0d 100755 --- a/fqcn-fixer.py +++ b/fqcn-fixer.py @@ -76,6 +76,13 @@ argparser.add_argument( default=[], help="path(s) to directories or files to skip.", ) +argparser.add_argument( + '--do-not-use-default-exclude', + dest="no_general_exclude_paths", + action='store_true', + default=False, + help="do not use the default excludes", + ) argparser.add_argument( '-c', '--config', dest="config", @@ -178,12 +185,15 @@ for fqcn in copy.copy(fqcndict).values(): # build exclude_paths exclude_paths = [] -for ep in args.exclude_paths + _general_exclude_paths: +for ep in args.exclude_paths: exclude_paths.append(ep) +if not args.no_general_exclude_paths: + for ep in _general_exclude_paths: + exclude_paths.append(ep) exclude_paths.append(args.fqcnmapfile) # update some args from optional config file -config = False +_config = False if args.config: try: with open(args.config) as ymlfile: