diff options
author | Chris Lamb <lamby@debian.org> | 2016-06-09 20:35:27 +0000 |
---|---|---|
committer | Chris Lamb <lamby@debian.org> | 2016-06-09 20:35:27 +0000 |
commit | 422ffaa841bc70b6b3bf132b59e457b0848bc8af (patch) | |
tree | 4094fd6377167b3719c19bd4a24fb45640b22e5a /bin/lts-cve-triage.py | |
parent | 61c5b6054f3914ab4048adb677d25b822fde3a0d (diff) |
Support excluding as well as filtering
git-svn-id: svn+ssh://svn.debian.org/svn/secure-testing@42427 e39458fd-73e7-0310-bf30-c45bca0a0e42
Diffstat (limited to 'bin/lts-cve-triage.py')
-rwxr-xr-x | bin/lts-cve-triage.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/lts-cve-triage.py b/bin/lts-cve-triage.py index fa05a4ce36..828844b9d5 100755 --- a/bin/lts-cve-triage.py +++ b/bin/lts-cve-triage.py @@ -53,6 +53,8 @@ parser.add_argument('--skip-cache-update', action='store_true', help='Skip updating the tracker data cache') parser.add_argument('--filter', nargs='+', choices=[x[0] for x in LIST_NAMES], help='Only report on specified lists') +parser.add_argument('--exclude', nargs='+', choices=[x[0] for x in LIST_NAMES], + help='Do not report on the specified lists') args = parser.parse_args() tracker = TrackerData(update_cache=not args.skip_cache_update) @@ -60,7 +62,6 @@ def add_to_list(key, pkg, issue): assert key in [l[0] for l in LIST_NAMES] lists[key][pkg].append(issue) - for pkg in tracker.iterate_packages(): if args.skip_dla_needed and pkg in tracker.dla_needed: continue @@ -106,6 +107,8 @@ for pkg in tracker.iterate_packages(): for key, desc in LIST_NAMES: if args.filter is not None and key not in args.filter: continue + if args.exclude is not None and key in args.exclude: + continue if not len(lists[key]): continue print('{}:'.format(desc)) |