🐛 sort csv by recipe name

This commit is contained in:
neingeist 2026-04-08 22:12:28 +02:00
parent 840b2e9a53
commit ee6409a40d

View file

@ -81,6 +81,7 @@ def main():
with open(os.path.join(OUTDIR_JSON, json_file), "r", encoding="utf-8") as f: with open(os.path.join(OUTDIR_JSON, json_file), "r", encoding="utf-8") as f:
data = json.load(f) data = json.load(f)
recipes.append(data) recipes.append(data)
recipes.sort(key=lambda r: r["name"])
# filter "Frühstück" # filter "Frühstück"
recipes = [r for r in recipes if any(k["name"] == "Fr\u00fchst\u00fcck" for k in r["keywords"])] recipes = [r for r in recipes if any(k["name"] == "Fr\u00fchst\u00fcck" for k in r["keywords"])]