test
Some checks failed
Update wiki / test (push) Failing after 17s

This commit is contained in:
Ashley Graves 2024-08-01 01:43:24 +02:00
parent c3c3b8a209
commit 7b12f0a38d

View file

@ -17,7 +17,6 @@ cache = dict()
if os.path.isfile("cache/licenses.json"):
with open("cache/licenses.json", "r") as f:
cache = json.load(f)
print(cache)
for mod in glob.glob("pack/mods/*.toml"):
with open(mod, "r") as f:
@ -99,15 +98,14 @@ with open("wiki/Modlist.md", "w") as f:
with open("wiki/Licenses.md", "w") as f:
for mod in mods:
data = mods[mod]
print(data)
data = mods[mod]["license"]
f.write("## " + mod + "\r\n")
f.write("<b>")
if "license" in data:
if data["license"]["url"] != None:
f.write("<a href=\"" + data["license"]["url"] + "\">" + data["license"] + "")
f.write("<a href=\"" + data["url"] + "\">" + data["name"] + "")
else:
f.write(data["license"]["name"])
f.write(data["name"])
else:
f.write("Unknown")
f.write("</b>\r\n")