README fixes
This commit is contained in:
parent
ba139706bb
commit
a3e8e89160
28
README.md
28
README.md
@ -19,12 +19,9 @@ library](https://anytree.readthedocs.io/en/latest/).
|
||||
### `create_recipe_json.py`
|
||||
|
||||
This is a fairly naive script that walks you through the process of turning a
|
||||
recipe into a tree structure. It has you list out ingredients, and then add
|
||||
tasks to perform on those ingredients.
|
||||
|
||||
You can add ingredients and then add tasks to perform on those ingredients.
|
||||
The results of those tasks can have more tasks applied to them, until you end
|
||||
up with your finished product.
|
||||
recipe into a tree structure. You add ingredients and then add tasks to perform
|
||||
on the ingredients. The results of those tasks can have further tasks applied
|
||||
to them, until you finally end up with your finished product.
|
||||
|
||||
The tree you build has a structure like this, with the last step at the root:
|
||||
|
||||
@ -46,14 +43,14 @@ shake and grill for 20 more mins
|
||||
|
||||
Leaves are raw ingredients, other nodes are tasks. A recipe can have multiple
|
||||
tree roots. Once you are done adding ingredients and tasks, all trees are
|
||||
output to a JSON file based on the name you give to the recipe.
|
||||
written to a JSON file based on the name you give to the recipe.
|
||||
|
||||
### `recipes2html.py`
|
||||
|
||||
***WARNING: These scripts do not sanitize most inputs!*** Parts of the JSON can
|
||||
have HTML which will be rendered out in the browser, which was very convenient
|
||||
for me but a terrible idea for security. **DO NOT RUN THIS CODE ON JSON YOU
|
||||
DID NOT CREATE YOURSELF!**
|
||||
***WARNING: These scripts do not sanitize most inputs!*** Fields parsed from
|
||||
the JSON can have HTML which will be rendered in the browser. This was very
|
||||
convenient for me but a terrible idea for security. **DO NOT RUN THIS CODE ON
|
||||
JSON YOU DID NOT CREATE YOURSELF!**
|
||||
|
||||
This script takes an argument pointing to a directory of recipe JSON files, in
|
||||
the format created by the `create_recipe_json.py` script. It then does a
|
||||
@ -67,8 +64,7 @@ file will be inserted into the header section of the generated `index.html`.
|
||||
- A single node cannot have multiple tasks done on it (nerdy reason: because a
|
||||
node cannot have two parents). So this cannot perfectly represent, for example,
|
||||
mixing cinnamon and sugar, then splitting that mixture up and doing separate
|
||||
subsequent operations with the two batches.
|
||||
This has come up once in my [zucchini bread
|
||||
recipe](https://tilde.town/~gamerdonkey/recipes/lemony_olive_oil_zucchini_bread.html),
|
||||
and I worked around the issue by just adding an instruction to set the
|
||||
ingredients aside and use them later.
|
||||
subsequent operations with the two batches. This has come up once in my
|
||||
[zucchini bread recipe](https://tilde.town/~gamerdonkey/recipes/lemony_olive_oil_zucchini_bread.html),
|
||||
and I worked around the issue by adding an instruction to set the ingredients
|
||||
aside and use them later.
|
||||
|
Loading…
x
Reference in New Issue
Block a user