diff --git a/readme.md b/readme.md new file mode 100644 index 0000000..8c3981f --- /dev/null +++ b/readme.md @@ -0,0 +1,15 @@ +# Badge Generator +Editing hundreds of badges by hand was a tedious and time consuming project, so it was automated with this script. + +## Why not the Pretix badge generator? +Pretix badge generator was particularly hard to use and special cases (like the custom background based on role) was pretty much impossible. + +## How does this work? +The script "gen_badges.py" will: +1. Fetch all orders from the pretix api +2. Fetch details from each order, and use it to edit a SVG template. Rather than using XML libraries, everything is done with python built-in ".replace()" function with no regards on potential XML corruption. +3. Render all the resultant SVG files to PDF (using inkscape) +4. Merge all the separate PDF files to a combined one (using pdfmerge) + +## How do i create the template? +Just use Inkscape and then manually edit the paths of the *.svg file or find out how to replace them. Make sure to "vacuum document" and "export as a regular SVG" so that the file is simpler and easier to edit. \ No newline at end of file