Skip to content
This repository has been archived by the owner on Mar 1, 2022. It is now read-only.

Latest commit

 

History

History
33 lines (23 loc) · 1.02 KB

README.md

File metadata and controls

33 lines (23 loc) · 1.02 KB

ecm.online invoice-generator

Generate invoices using python, weasyprint and yaml. Just add your data to documents/invoice/data.yml and run the ./buildpdf.py script.

Current template looks like this:

rendered invoice

Usage see ./buildpdf.py --help:

usage: buildpdf.py [-h] [--template TEMPLATE] [--yaml_file YAML_FILE]
                [--output_pdf OUTPUT_PDF] [--locale LOCALE]

Convert HTML template to pdf with data from yaml

optional arguments:
-h, --help            show this help message and exit
--template TEMPLATE   The name of the template to use (e.g. invoice)
--yaml_file YAML_FILE
                        The yaml file to use for data
--output_pdf OUTPUT_PDF
                        The output pdf file
--locale LOCALE       The locale to use

Docker

docker build -t invoice .
docker run -it --rm -v /Users/philippbraun/Desktop/invoice-generator:/root -p 8000:8000 invoice