fix: [tools] website and README list generator are now the same

pull/207/head
Alexandre Dulaunoy 2021-03-25 11:35:21 +01:00
parent 90aa8a6d54
commit 24e95b149b
No known key found for this signature in database
GPG Key ID: 09E2CD4944E6CBCD
1 changed files with 5 additions and 2 deletions

View File

@ -1,9 +1,12 @@
import json
import os
import re
filename = os.path.join("../", "MANIFEST.json")
with open(filename) as fp:
t = json.load(fp)
t = json.load(fp)
for taxo in sorted(t['taxonomies'], key=lambda k: k['name']):
print ("[{}](https://github.com/MISP/misp-taxonomies/tree/master/{}):\n: {}[HTML](https://www.misp-project.org/taxonomies.html#_{})\n".format(taxo['name'], taxo['name'], taxo['description'], re.sub(r'-', '_',taxo['name'])))
print("### {}".format(taxo['name']))
print()
print("[{}](https://github.com/MISP/misp-taxonomies/tree/main/{}) :\n{} [Overview](https://www.misp-project.org/taxonomies.html#_{})\n".format(taxo['name'], taxo['name'], taxo['description'], re.sub(r'-', '_',taxo['name'])))