mirror of
https://github.com/mandiant/capa.git
synced 2025-12-23 07:28:34 -08:00
scripts: migrate-rule: respect lib meta
This commit is contained in:
@@ -126,6 +126,8 @@ def main(argv=None):
|
|||||||
directory = os.path.join(args.destination, "nursery")
|
directory = os.path.join(args.destination, "nursery")
|
||||||
# this isn't meant to be written into the rule
|
# this isn't meant to be written into the rule
|
||||||
del rule.meta["nursery"]
|
del rule.meta["nursery"]
|
||||||
|
elif rule.meta.get("lib"):
|
||||||
|
directory = os.path.join(args.destination, "lib")
|
||||||
else:
|
else:
|
||||||
directory = os.path.join(args.destination, rule.meta.get("namespace"))
|
directory = os.path.join(args.destination, rule.meta.get("namespace"))
|
||||||
os.makedirs(directory)
|
os.makedirs(directory)
|
||||||
|
|||||||
Reference in New Issue
Block a user