mirror of
https://github.com/derrod/legendary.git
synced 2025-01-20 06:21:34 +00:00
[cli] Filter files by install tag before verifying
This commit is contained in:
parent
bb3d6f9348
commit
dd3c0429fe
|
@ -800,7 +800,16 @@ class LegendaryCLI:
|
||||||
key=lambda a: a.filename.lower())
|
key=lambda a: a.filename.lower())
|
||||||
|
|
||||||
# build list of hashes
|
# build list of hashes
|
||||||
file_list = [(f.filename, f.sha_hash.hex()) for f in files]
|
if config_tags := self.core.lgd.config.get(args.app_name, 'install_tags', fallback=None):
|
||||||
|
install_tags = set(i.strip() for i in config_tags.split(','))
|
||||||
|
file_list = [
|
||||||
|
(f.filename, f.sha_hash.hex())
|
||||||
|
for f in files
|
||||||
|
if any(it in install_tags for it in f.install_tags) or not f.install_tags
|
||||||
|
]
|
||||||
|
else:
|
||||||
|
file_list = [(f.filename, f.sha_hash.hex()) for f in files]
|
||||||
|
|
||||||
total = len(file_list)
|
total = len(file_list)
|
||||||
num = 0
|
num = 0
|
||||||
failed = []
|
failed = []
|
||||||
|
|
Loading…
Reference in a new issue