|
|
||
|---|---|---|
| brandbooks/default | ||
| data | ||
| docs | ||
| plan | ||
| scripts | ||
| src/md2brandtk | ||
| tests | ||
| .gitignore | ||
| README.md | ||
| pytest.ini | ||
| requirements.txt | ||
| test1.html | ||
| test2.html | ||
| test3.html | ||
| test3.pdf | ||
README.md
md2brandtk
CLI renders a multi-part document from Markdown front matter and a brandbook contract.
Usage
python scripts/render_document.py --input data/sample.md --brandbook default --output output/pdf/sample.pdf
Options:
--tmp-dir: temporary folder for intermediate PDFs (default:tmp/pdfs)--strict: fail on unknown Jinja placeholdersMD2BRANDTK_FAKE_RENDER=1: render blank placeholder PDFs instead of invoking WeasyPrint
Input and contracts
- Markdown contract:
docs/md-contract.md - Brandbook contract:
docs/brandbook-contract.md
Tests
python -m pytest -q tests/unit
python -m pytest -q -m smoke