1
0
mirror of https://codeberg.org/fediverse/fep.git synced 2026-08-05 19:55:46 +00:00
Files
fep/scripts/create_readme.py
T

18 lines
350 B
Python
Executable File

#!/usr/bin/env python
import json
from tools import index, Readme
with open("README.md", "w") as f1:
f1.writelines(Readme().content)
result = []
for fep in index():
data = fep.parsed_frontmatter
data["title"] = fep.title
result.append(data)
with open("index.json", "w") as index_file:
json.dump(result, index_file, indent=2)