From 9a7b5e6af0220c7124c772048959839ccf3b2edf Mon Sep 17 00:00:00 2001 From: Kelvin Sherlock Date: Tue, 23 Feb 2021 22:41:26 -0500 Subject: [PATCH] add the software list to the machine description --- python/mkmachines.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/python/mkmachines.py b/python/mkmachines.py index 2e83f3b..ce5f133 100644 --- a/python/mkmachines.py +++ b/python/mkmachines.py @@ -167,6 +167,11 @@ def find_media(parent, include_slots=False): if not media: return None return media + +def find_software(parent): + swl = parent.findall("./softwarelist") + return [x.get("name") + ".xml" for x in swl] + devices = {} p = argparse.ArgumentParser() @@ -256,6 +261,9 @@ for m in machines: data[s] = tmp + data["software"] = find_software(machine) + + path = "../Ample/Resources/{}.plist".format(m) with open(path, "w") as f: f.write(to_plist(data))