Report
The report
command generates custom reports from recipes using minijinja templates. It's a powerful tool for creating recipe cards, nutrition labels, meal plans, or any custom format you need.
⚠️ Note: The report command is currently a prototype feature and will evolve in future versions.
Basic Usage
This processes the recipe through the template and outputs the result.
How It Works
The report command:
- Parses the recipe file
- Applies any scaling
- Loads aisle and pantry configurations (if provided)
- Passes recipe data to the Jinja2 template
- Outputs the rendered result
Template Variables
Templates receive comprehensive recipe data:
Recipe Object
Ingredients
Steps
Metadata
Using All Configurations Together
Outputs:
This provides the template with:
- Scaled recipe (2x)
- Nutritional and cost data from datastore
- Aisle categorization for shopping
- Pantry inventory for filtering (excludes items you already have)
Example Templates
Simple Recipe Card
Create recipe-card.jinja
:
Use it:
Checkout more reports here.
Scaling Recipes
Scale recipes before processing:
Configuration Options
Datastore
Include additional data from a datastore:
The datastore can contain:
- Nutritional information
- Cost data
- Dietary classifications
- Custom metadata
Aisle Configuration
Categorize ingredients by store section:
Template can access:
Pantry Configuration
Filter out pantry items using your inventory:
The pantry.conf file tracks your inventory with quantities and dates:
Template can check pantry items:
Output Options
Save to File
Advanced Templates
Conditional Content
Formatted Output
Calculations
Practical Examples
Meal Planning
Create weekly-plan.jinja
:
Generate weekly plan:
Recipe Book
Create book-page.jinja
:
Index Generation
Create index.jinja
:
Generate index:
Reusable Components
Create base.jinja
:
Use in other templates:
Integration Examples
PDF Generation
Email Newsletter
Social Media
Create social.jinja
:
Tips and Tricks
Default Values
Filters
Loops with Conditions
Troubleshooting
Template Not Found
Variable Errors
If a variable doesn't exist:
See Also
- Recipe – View recipe data structure
- Shopping List – Generate shopping lists
- Server – Web-based recipe viewing