Skip to content

Commit

Permalink
edit some recipes to fit booklet printing better (total pages divisib…
Browse files Browse the repository at this point in the history
…le by 4), and improve overall look of printed pages. improve pdf generation script output
  • Loading branch information
fexofenadine committed Dec 23, 2023
1 parent d774af0 commit 1684d7c
Show file tree
Hide file tree
Showing 25 changed files with 77 additions and 100 deletions.
Binary file modified gitFOOD_Recipe_Book.pdf
Binary file not shown.
Binary file modified pdf/0_3_title_page.pdf
Binary file not shown.
Binary file modified pdf/2_frenchtoastwhippedcreamcheese.pdf
Binary file not shown.
Binary file modified pdf/5_applecrumble.pdf
Binary file not shown.
Binary file modified pdf/6_cheesypotatopockets.pdf
Binary file not shown.
Binary file added pdf/9_applecrumble.temp.pdf
Binary file not shown.
Binary file modified pdf/9_hommus.pdf
Binary file not shown.
Binary file removed pdf/9_lasagnaairfryer.pdf
Binary file not shown.
Binary file added pdf/applecrumble.temp.pdf
Binary file not shown.
3 changes: 1 addition & 2 deletions recipes/applecrumble.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
- ¼ cup water
- 1 tbsp lemon juice
- 1 tbsp brown sugar
- [optional] 2 tbsp sultanas, raisins, or currants
- [optional] ¼ tsp ground cinnamon

### Crumble
Expand All @@ -24,7 +23,7 @@

## Method

> 1. Preheat oven to 180°C/160°C fan forced. Combine apples, sultanas, juice, sugar, cinnamon, and water in small saucepan over medium heat. Cook, stirring for 5 minutes or until apple is slightly softened. Leave in the pan to soak/soften.
> 1. Preheat oven to 180°C/160°C fan forced. Combine apples, juice, sugar, cinnamon, and water in small saucepan over medium heat. Cook, stirring for 5 minutes or until apple is slightly softened. Leave in the pan to soak/soften.
> 1. To make the crumble, combine the flour, sugar, oats, cinnamon, nutmeg, and butter in a bowl. Use your fingertips to rub the butter into the flour mixture until the mixture resembles breadcrumbs. <img src="applecrumble/images/1.jpg" width="35%" align="right" />
> 1. Transfer the apples into a 3 cup capacity ovenproof dish, draining off most of the liquid. Sprinkle crumble mixture over the apples. Bake in oven for 25-30 minutes or until golden brown.
> 1. Serve warm with custard, icecream or whipped cream.
Expand Down
38 changes: 38 additions & 0 deletions recipes/applecrumble.temp.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<img src="applecrumble/images/main.jpg" width="55%" align="right" />

# Apple Crumble

## Ingredients

### Filling

- 3 medium apples, peeled, cored, and sliced (about 2mm or so thick)
- ¼ cup water
- 1 tbsp lemon juice
- 1 tbsp brown sugar
- [optional] ¼ tsp ground cinnamon

### Crumble

- ⅓ cup plain flour
- ⅓ cup brown sugar
- ⅓ cup rolled oats
- 60g butter, chopped
- [optional] ¼ tsp ground cinnamon
- [optional] ¼ tsp ground nutmeg

## Method

> 1. Preheat oven to 180°C/160°C fan forced. Combine apples, juice, sugar, cinnamon, and water in small saucepan over medium heat. Cook, stirring for 5 minutes or until apple is slightly softened. Leave in the pan to soak/soften.
> 1. To make the crumble, combine the flour, sugar, oats, cinnamon, nutmeg, and butter in a bowl. Use your fingertips to rub the butter into the flour mixture until the mixture resembles breadcrumbs. <img src="applecrumble/images/1.jpg" width="35%" align="right" />
> 1. Transfer the apples into a 3 cup capacity ovenproof dish, draining off most of the liquid. Sprinkle crumble mixture over the apples. Bake in oven for 25-30 minutes or until golden brown.
> 1. Serve warm with custard, icecream or whipped cream.
## Tips

> - Soften the butter for a few seconds in the microwave if it's too solid to squish between fingertips reasonably easily. It should remain solid and not at all runny for the crumble.
> - Using brown sugar will give the dish a slightly rich, carameled taste and colour, but caster sugar can be easily swapped in for a lovely variation!


<img src="https://img.shields.io/badge/baked-blue.svg" /> <img src="https://img.shields.io/badge/dessert-blue.svg" /> <img src="https://img.shields.io/badge/stovetop-blue.svg" /> <img src="https://img.shields.io/badge/vegan-blue.svg" /> <img src="https://img.shields.io/badge/vegetarian-blue.svg" />
3 changes: 1 addition & 2 deletions recipes/applecrumble/applecrumble.recipe
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
- ¼ cup water
- 1 tbsp lemon juice
- 1 tbsp brown sugar
- [optional] 2 tbsp sultanas, raisins, or currants
- [optional] ¼ tsp ground cinnamon

### Crumble
Expand All @@ -24,7 +23,7 @@

## Method

> 1. Preheat oven to 180°C/160°C fan forced. Combine apples, sultanas, juice, sugar, cinnamon, and water in small saucepan over medium heat. Cook, stirring for 5 minutes or until apple is slightly softened. Leave in the pan to soak/soften.
> 1. Preheat oven to 180°C/160°C fan forced. Combine apples, juice, sugar, cinnamon, and water in small saucepan over medium heat. Cook, stirring for 5 minutes or until apple is slightly softened. Leave in the pan to soak/soften.
> 1. To make the crumble, combine the flour, sugar, oats, cinnamon, nutmeg, and butter in a bowl. Use your fingertips to rub the butter into the flour mixture until the mixture resembles breadcrumbs. {1.jpg}
> 1. Transfer the apples into a 3 cup capacity ovenproof dish, draining off most of the liquid. Sprinkle crumble mixture over the apples. Bake in oven for 25-30 minutes or until golden brown.
> 1. Serve warm with custard, icecream or whipped cream.
Expand Down
3 changes: 0 additions & 3 deletions recipes/cheesypotatopockets.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@
> 1. Remove potatoes from the oven and cut them in half. With a spoon, scoop out the flesh and place it into a bowl.
> 1. In the bowl add cheese, spring onions, mustard, salt, and pepper, and any additional/optional ingredients, mashing everything together.
> 1. Fill the potato skins with the cheesy potato mixture and sprinkle some cheese on top.
> 1. Bake at 180°C in the oven for 20 minutes or until golden and crispy on top.

<img src="../images/logo_sm.png" width="40%" />

Expand Down
4 changes: 1 addition & 3 deletions recipes/cheesypotatopockets/cheesypotatopockets.recipe
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,4 @@
> 1. Place potatoes in a baking dish and bake at 180°C for 1 hour.
> 1. Remove potatoes from the oven and cut them in half. With a spoon, scoop out the flesh and place it into a bowl.
> 1. In the bowl add cheese, spring onions, mustard, salt, and pepper, and any additional/optional ingredients, mashing everything together.
> 1. Fill the potato skins with the cheesy potato mixture and sprinkle some cheese on top.
> 1. Bake at 180°C in the oven for 20 minutes or until golden and crispy on top.

> 1. Fill the potato skins with the cheesy potato mixture and sprinkle some cheese on top.
9 changes: 1 addition & 8 deletions recipes/frenchtoastwhippedcreamcheese.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@

### Bread batter

(enough for 1 loaf of sourdough (~14 small-medium sized slices))
Serves 4-5

- 1 loaf of sourdough, slightly older will hold together best. Other breads may work well too.
- 1 loaf of sliced sourdough, slightly older will hold together best. Other breads may work well too.
- 6 eggs
- 1½ cups milk
- 2 tsp vanilla extract
Expand All @@ -32,10 +29,6 @@ Serves 4-5
## Variations

> - Many other toppings, including icing sugar, ice cream, chocolate syrup, berries, agave nectar. Anything that's good on a pancake will probably be great here.
> - Use a multigrain bread for a little more texture and extra fibre.
*Last updated 21 Jan 2023, 11:52:22*

<img src="../images/logo_sm.png" width="40%" />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@

### Bread batter

(enough for 1 loaf of sourdough (~14 small-medium sized slices))
Serves 4-5

- 1 loaf of sourdough, slightly older will hold together best. Other breads may work well too.
- 1 loaf of sliced sourdough, slightly older will hold together best. Other breads may work well too.
- 6 eggs
- 1½ cups milk
- 2 tsp vanilla extract
Expand All @@ -31,7 +28,4 @@ Serves 4-5

## Variations

> - Many other toppings, including icing sugar, ice cream, chocolate syrup, berries, agave nectar. Anything that's good on a pancake will probably be great here.
> - Use a multigrain bread for a little more texture and extra fibre.

*Last updated 21 Jan 2023, 11:52:22*
> - Many other toppings, including icing sugar, ice cream, chocolate syrup, berries, agave nectar. Anything that's good on a pancake will probably be great here.
25 changes: 11 additions & 14 deletions recipes/hommus.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,27 @@

## Ingredients

- 1 can (425g) chickpeas, rinsed and drained, or 1 ½ cups cooked chickpeas-
- 425g can (or 1½ cups cooked) chickpeas, rinsed and drained
- ½ tsp baking soda (if you’re using canned chickpeas)
- ¼ cup lemon juice (from 1½ to 2 lemons), more to taste
- 1 medium-to-large clove garlic, roughly chopped
- 1 medium-large clove garlic, roughly chopped
- ½ tsp fine sea salt, to taste
- ½ cup tahini
- 2 to 4 tablespoons ice water, more as needed
- ½ tsp ground cumin
- 1 tbsp extra-virgin olive oil
- Any of the following garnishes: drizzle of olive oil or zhoug sauce, sprinkle of ground sumac or paprika, chopped fresh parsley
- 1 tbsp extra virgin olive oil
- [optional garnishes] olive oil/zhoug sauce/ground sumac/paprika/fresh parsley


## Method

> 1. Place the chickpeas in a medium saucepan and add the baking soda. Cover the chickpeas by several (5 to 10) cm of water, then bring the mixture to a boil over high heat. Continue boiling, reducing heat if necessary to prevent overflow, for about 20 minutes, or until the chickpeas look bloated, their skins are falling off, and they’re quite soft. In a fine mesh strainer, drain the chickpeas and run cool water over them for about 30 seconds. Set aside (no need to peel the chickpeas for this recipe!).
> 2. Meanwhile, in a food processor or high-powered blender, combine the lemon juice, garlic and salt. Process until the garlic is very finely chopped, then let the mixture rest so the garlic flavor can mellow, ideally 10 minutes or longer.
> 3. Add the tahini to the food processor and blend until the mixture is thick and creamy, stopping to scrape down any tahini stuck to the sides and bottom of +the processor as necessary.
> 4. While running the food processor, drizzle in 2 tablespoons ice water. Scrape down the food processor, and blend until the mixture is ultra smooth, pale and creamy. (If your tahini was extra-thick to begin with, you might need to add 1 to 2 tablespoons more ice water.)
> 5. Add the cumin and the drained, over-cooked chickpeas to the food processor. While blending, drizzle in the olive oil. Blend until the mixture is super smooth, scraping down the sides of the processor as necessary, about 2 minutes. Add more ice water by the tablespoon if necessary to achieve a super creamy texture.
> 6. Taste, and adjust as necessary—I almost always add another ¼ teaspoon salt for more overall flavor and another tablespoon of lemon juice for extra zing.
> 7. Scrape the hommus into a serving bowl or platter, and use a spoon to create nice swooshes on top. Top with garnishes of your choice, and serve. Leftover hommus keeps well in the refrigerator, covered, for up to 1 week.
*Last updated 25 Apr 2023, 05:20:52*

> 1. Place the chickpeas in a medium saucepan and add the baking soda. Cover the chickpeas by several (5 to 10) cm of water, then bring the mixture to a boil over high heat. Continue boiling, reducing heat if necessary to prevent overflow, for about 20 minutes, or until the chickpeas look bloated, their skins are falling off, and they’re quite soft. In a fine mesh strainer, drain the chickpeas and run cool water over them for about 30 seconds.
> 1. Meanwhile, in a food processor or high-powered blender, combine the lemon juice, garlic and salt. Process until the garlic is very finely chopped, then let the mixture rest so the garlic flavor can mellow, ideally 10 minutes or longer.
> 1. Add the tahini to the food processor and blend until the mixture is thick and creamy, stopping to scrape down any tahini stuck to the sides and bottom of +the processor as necessary.
> 1. While running the food processor, drizzle in 2 tablespoons ice water. Scrape down the food processor, and blend until the mixture is ultra smooth, pale and creamy. (If your tahini was extra-thick to begin with, you might need to add 1 to 2 tablespoons more ice water.)
> 1. Add the cumin and the drained chickpeas to the food processor. While blending, drizzle in the olive oil. Blend until the mixture is super smooth, scraping down the sides of the processor as necessary, about 2 minutes. Add more ice water by the tablespoon if necessary to achieve a super creamy texture.
> 1. Taste, and adjust as necessary. Add another ¼ teaspoon salt for more flavor or extra lemon juice for more zing.
> 1. Scrape the hommus into a serving bowl or platter, and use a spoon to create nice swooshes on top. Top with garnishes of your choice, and serve.
<img src="../images/logo_sm.png" width="40%" />

Expand Down
24 changes: 11 additions & 13 deletions recipes/hommus/hommus.recipe
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,24 @@

## Ingredients

- 1 can (425g) chickpeas, rinsed and drained, or 1 ½ cups cooked chickpeas-
- 425g can (or 1½ cups cooked) chickpeas, rinsed and drained
- ½ tsp baking soda (if you’re using canned chickpeas)
- ¼ cup lemon juice (from 1½ to 2 lemons), more to taste
- 1 medium-to-large clove garlic, roughly chopped
- 1 medium-large clove garlic, roughly chopped
- ½ tsp fine sea salt, to taste
- ½ cup tahini
- 2 to 4 tablespoons ice water, more as needed
- ½ tsp ground cumin
- 1 tbsp extra-virgin olive oil
- Any of the following garnishes: drizzle of olive oil or zhoug sauce, sprinkle of ground sumac or paprika, chopped fresh parsley
- 1 tbsp extra virgin olive oil
- [optional garnishes] olive oil/zhoug sauce/ground sumac/paprika/fresh parsley


## Method

> 1. Place the chickpeas in a medium saucepan and add the baking soda. Cover the chickpeas by several (5 to 10) cm of water, then bring the mixture to a boil over high heat. Continue boiling, reducing heat if necessary to prevent overflow, for about 20 minutes, or until the chickpeas look bloated, their skins are falling off, and they’re quite soft. In a fine mesh strainer, drain the chickpeas and run cool water over them for about 30 seconds. Set aside (no need to peel the chickpeas for this recipe!).
> 2. Meanwhile, in a food processor or high-powered blender, combine the lemon juice, garlic and salt. Process until the garlic is very finely chopped, then let the mixture rest so the garlic flavor can mellow, ideally 10 minutes or longer.
> 3. Add the tahini to the food processor and blend until the mixture is thick and creamy, stopping to scrape down any tahini stuck to the sides and bottom of +the processor as necessary.
> 4. While running the food processor, drizzle in 2 tablespoons ice water. Scrape down the food processor, and blend until the mixture is ultra smooth, pale and creamy. (If your tahini was extra-thick to begin with, you might need to add 1 to 2 tablespoons more ice water.)
> 5. Add the cumin and the drained, over-cooked chickpeas to the food processor. While blending, drizzle in the olive oil. Blend until the mixture is super smooth, scraping down the sides of the processor as necessary, about 2 minutes. Add more ice water by the tablespoon if necessary to achieve a super creamy texture.
> 6. Taste, and adjust as necessary—I almost always add another ¼ teaspoon salt for more overall flavor and another tablespoon of lemon juice for extra zing.
> 7. Scrape the hommus into a serving bowl or platter, and use a spoon to create nice swooshes on top. Top with garnishes of your choice, and serve. Leftover hommus keeps well in the refrigerator, covered, for up to 1 week.

*Last updated 25 Apr 2023, 05:20:52*
> 1. Place the chickpeas in a medium saucepan and add the baking soda. Cover the chickpeas by several (5 to 10) cm of water, then bring the mixture to a boil over high heat. Continue boiling, reducing heat if necessary to prevent overflow, for about 20 minutes, or until the chickpeas look bloated, their skins are falling off, and they’re quite soft. In a fine mesh strainer, drain the chickpeas and run cool water over them for about 30 seconds.
> 1. Meanwhile, in a food processor or high-powered blender, combine the lemon juice, garlic and salt. Process until the garlic is very finely chopped, then let the mixture rest so the garlic flavor can mellow, ideally 10 minutes or longer.
> 1. Add the tahini to the food processor and blend until the mixture is thick and creamy, stopping to scrape down any tahini stuck to the sides and bottom of +the processor as necessary.
> 1. While running the food processor, drizzle in 2 tablespoons ice water. Scrape down the food processor, and blend until the mixture is ultra smooth, pale and creamy. (If your tahini was extra-thick to begin with, you might need to add 1 to 2 tablespoons more ice water.)
> 1. Add the cumin and the drained chickpeas to the food processor. While blending, drizzle in the olive oil. Blend until the mixture is super smooth, scraping down the sides of the processor as necessary, about 2 minutes. Add more ice water by the tablespoon if necessary to achieve a super creamy texture.
> 1. Taste, and adjust as necessary. Add another ¼ teaspoon salt for more flavor or extra lemon juice for more zing.
> 1. Scrape the hommus into a serving bowl or platter, and use a spoon to create nice swooshes on top. Top with garnishes of your choice, and serve.
15 changes: 0 additions & 15 deletions recipes/lasagnaairfryer.md

This file was deleted.

Binary file removed recipes/lasagnaairfryer/images/main.jpg
Binary file not shown.
9 changes: 0 additions & 9 deletions recipes/lasagnaairfryer/lasagnaairfryer.recipe

This file was deleted.

7 changes: 0 additions & 7 deletions recipes/lasagnaairfryer/tags.txt

This file was deleted.

20 changes: 10 additions & 10 deletions scripts/generate_pdfs.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,23 +99,23 @@ def custom_strftime(format, t):
finally:
f.close()
if 'snack' in list(tags):
category='1'
category=('1','snacks')
elif 'breakfast' in list(tags):
category='2'
category=('2','breakfast')
elif 'lunch' in list(tags):
category='3'
category=('3','lunch')
elif 'dinner' in list(tags):
category='4'
category=('4','dinner')
elif 'dessert' in list(tags):
category='5'
category=('5','dessert')
elif 'sides' in list(tags):
category='6'
category=('6','sides')
else:
category='9'
print('category '+category+' detected in tag file')
category=('9','extra stuff')
print('primary category '+category[0]+' ['+category[1]+'] detected in tag file')
try:
recipe_md_modified=os.path.getmtime(recipe_md)
recipe_pdf_modified=os.path.getmtime('./pdf/'+category+'_'+recipe_name+'.pdf')
recipe_pdf_modified=os.path.getmtime('./pdf/'+category[0]+'_'+recipe_name+'.pdf')
except:
# regenerate pdf if a file is missing (ie. if it hasn't been created yet)
recipe_md_modified=1
Expand All @@ -142,7 +142,7 @@ def custom_strftime(format, t):
print('exporting to ./pdf/'+recipe_name+'.temp.pdf')
os.system('cd ./recipes && pandoc -f gfm --quiet -t html5 -V papersize:a4 -V geometry:margin=2cm -V mainfont:"Helvetica Rounded" -V mainfontoptions:"Scale=1.1" -V fontsize=20pt -V documentclass=book --pdf-engine-opt=--enable-local-file-access --dpi 70 ./'+recipe_name+'.temp.md -o ../pdf/'+recipe_name+'.temp.pdf')
print('optimizing ./pdf/'+recipe_name+'.pdf for printing')
os.system('cd ./pdf && ghostscript -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/printer -dNOPAUSE -dQUIET -dBATCH -sOutputFile=./'+category+'_'+recipe_name+'.pdf ./'+recipe_name+'.temp.pdf')
os.system('cd ./pdf && ghostscript -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/printer -dNOPAUSE -dQUIET -dBATCH -sOutputFile=./'+category[0]+'_'+recipe_name+'.pdf ./'+recipe_name+'.temp.pdf')

print('removing temp files')
try:
Expand Down
Loading

0 comments on commit 1684d7c

Please sign in to comment.