diff options
author | Birte Kristina Friesel <birte.friesel@uos.de> | 2024-02-09 09:49:17 +0100 |
---|---|---|
committer | Birte Kristina Friesel <birte.friesel@uos.de> | 2024-02-09 09:49:17 +0100 |
commit | a721aca982b80240e2cbd6ecdac0abc7f13cccdf (patch) | |
tree | c3db21db9fb3b3cb21a431025b2217b8340b49c7 /bin | |
parent | cfc77a403e9487580a966669cc4be0f90d464d62 (diff) |
filter-param: support parameter names ending with '!'
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/analyze-archive.py | 21 | ||||
-rwxr-xr-x | bin/analyze-kconfig.py | 7 | ||||
-rwxr-xr-x | bin/analyze-log.py | 7 |
3 files changed, 26 insertions, 9 deletions
diff --git a/bin/analyze-archive.py b/bin/analyze-archive.py index e79d690..a5c0002 100755 --- a/bin/analyze-archive.py +++ b/bin/analyze-archive.py @@ -283,13 +283,6 @@ def main(): show_quality = args.show_quality - if args.filter_param: - args.filter_param = list( - map(dfatool.cli.parse_filter_string, args.filter_param.split(";")) - ) - else: - args.filter_param = list() - if args.filter_observation: args.filter_observation = list( map(lambda x: tuple(x.split(":")), args.filter_observation.split(",")) @@ -388,6 +381,20 @@ def main(): args.ignore_param = args.ignore_param.split(",") dfatool.utils.ignore_param(by_name, parameters, args.ignore_param) + if args.filter_param: + print(parameters) + args.filter_param = list( + map( + lambda entry: dfatool.cli.parse_filter_string( + entry, parameter_names=parameters + ), + args.filter_param.split(";"), + ) + ) + print(args.filter_param) + else: + args.filter_param = list() + dfatool.utils.filter_aggregate_by_param(by_name, parameters, args.filter_param) dfatool.utils.filter_aggregate_by_observation(by_name, args.filter_observation) diff --git a/bin/analyze-kconfig.py b/bin/analyze-kconfig.py index 3187609..5791e57 100755 --- a/bin/analyze-kconfig.py +++ b/bin/analyze-kconfig.py @@ -295,7 +295,12 @@ def main(): if args.filter_param: args.filter_param = list( - map(dfatool.cli.parse_filter_string, args.filter_param.split(";")) + map( + lambda entry: dfatool.cli.parse_filter_string( + entry, parameter_names=parameters + ), + args.filter_param.split(";"), + ) ) dfatool.utils.filter_aggregate_by_param( by_name, parameter_names, args.filter_param diff --git a/bin/analyze-log.py b/bin/analyze-log.py index 6fa279a..05814e6 100755 --- a/bin/analyze-log.py +++ b/bin/analyze-log.py @@ -63,7 +63,12 @@ def main(): if args.filter_param: args.filter_param = list( - map(dfatool.cli.parse_filter_string, args.filter_param.split(";")) + map( + lambda entry: dfatool.cli.parse_filter_string( + entry, parameter_names=parameters + ), + args.filter_param.split(";"), + ) ) else: args.filter_param = list() |