-
-
Notifications
You must be signed in to change notification settings - Fork 10
Guiding Principles
These are the guiding principles behind pystitcher. When in doubt regarding a change, check here.
Stitching together complex PDFs (For simpler usecases you should instead look at pdftk
or stapler) is not something that happens in one-shot. It is something you tweak and retry till you get it right. Having a declarative approach (where we use Markdown as the input language) makes for a simpler experience where your input is essentially defining the intended PDF structure.
The default values should work for majority of the use-cases.
Relying on a dependency such as Java (for pdftk) or ghostscript ends up causing a ton of issues for users. It is better to avoid such issues by sticking to 100% python.
If something is not achievable in pure python, then let the package installation and usage experience not be hampered by such issues. In other words, gracefully degrade the user experience while allowing for most of the usecases (and warn the user at install or runtime about which features are unavailable).
pystitcher
should act as a generic PDF merging toolkit for other applications. (This is currently not true, as pystitcher does not have a stable API or documentation.
CLI arguments just don't have the flexibility required for complex rules. As an example, see the complex --rule
flag that pdfmerge used. pystitcher limits command line flags to the tool's functioning (debug/cleanup etc) instead of document configuration.
Don't support unsupported python releases.