Description
Command line Python program to extract army rules and unit cards from 10th edition Warhammer 40k indexes to create army list specific pdfs with reduced file size. Requires Python.
Instructions
- Download an army index https://www.warhammer-community.com/warhammer-40000-downloads/#indexes-faqs-and-errata
- Install Python
- Install py40kie using pip:
pip install -U py40kie - Run py40kie using command line:
py40kie [-h] [-i EXTRA_INDEXES [EXTRA_INDEXES ...]] [-o OUTPUT_PDF] [-b] [-a] [-d] [-s] [-e] [-w] [-na] [-nd] [-ns] [-ne] [-nw] [-r RULE_PAGES [RULE_PAGES ...]] [-v] index_pdf pages [pages ...]
Army List builder instructions
- Create army list with Google Sheet army list builder
- Run the generated py40kie command
Examples
py40kie "Tyranids Index.pdf" 9 21 25 27 -o "my army list"
py40kie "Tyranids Index.pdf" "hive tyrant" "tyranid warriors with ranged bio-weapons" 25 "hOrMaGaUnTs" -o "./my lists/my army list"
py40kie "Space Wolves Index.pdf" 7 1-23 "Blood Claws" 1-53 "terminator squad" "2-culexus assassin" 2-7 3-1 -o "Best Army List Ever.pdf" -i "Space Marines Index.pdf" "Agents of Imperium Index.pdf" "Imperial Armour Astartes.pdf"
py40kie "Blood Angels Index.pdf" "Commander Dante" "Sanguinary Guard" "Lieutenant in Phobos Armour" "Death Company Marines" "Astraeus" "Culexus Assassin" "Knight Gallant" -o "super competitive list.pdf" -i "Astartes Index.pdf" "Imperial Armour Astartes.pdf" "Agents of the Imperium Index.pdf" "Imperial Knights Index.pdf"
Arguments
Postional arguments
- The "index.pdf" file to extract cards from
- Space separated list of cards to extract. Can be page numbers or **exact** unit titles. Army rules, detachment rules, stratagems, enhancements and unit wargear are included automatically
Optional arguments:
- -o: The file to save the extracted pdf to. Folder path can be included
- -i: Optional space separated list of additional pdfs to extract allied units from other Indexes/Imperial Armour/Legends ("1-10" to extract the card on page 10 from the first additional pdf). Also use this to extract the Adeptus Astartes army rule when using Space Marines
- -b: Optional flag for boarding actions (extracts the army rules page but not the detachment or stratagem pages)
- -na: Optional flag to disable extracting the army rules page
- -nd: Optional flag to disable extracting the detachment rules page
- -ns: Optional flag to disable extracting the stratagem pages
- -ne: Optional flag to disable extracting the enhancements page
- -nw: Optional flag to disable extracting wargear pages
- -r: Optional argument to specify army rules and stratagem pages (space separated numbers). Use this if the army rules and stratagems are not successfully extracted from the index
- -v: Optional flag to override page extraction. Will extract only the page numbers specified from the main index
Contributions
Future features
Any suggested features would be appreciated
- Allied units from other Indexes/Imperial Armour/Legends
- Extract Adeptus Astartes army rule page for Space Marine lists
- Create runnable command from Google Sheet army builder lists
Example Sheet
Original creator u/Swelt - Extract extra rule pages. e.g. Deathwatch Armoury
- Handle exceptions gracefully
- Webapp version?...
Issues
py40kie was not tested on all indexes. If there is any problem extracting cards please submit an issue https://github.com/Dragons-Ire/40k-index-pdf-extractor/issues/new
Metadata
Release files for py40kie 0.2.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| py40kie-0.2.2.tar.gz | 7.5 kB | Without provenance | Details for py40kie-0.2.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| py40kie-0.2.2-py3-none-any.whl | Python 3 | none | any | Details for py40kie-0.2.2-py3-none-any.whl |
Total release size: 14.1 kB
Release files / py40kie-0.2.2.tar.gz
| Download URL | py40kie-0.2.2.tar.gz |
|---|---|
| Size | 7.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9e5351a8583a9a1ab7dd29fa7f39bc8bf601785bcd1ccbf733a2dd6dc8f9657a
|
|
BLAKE2b-256 checksum How to use checksums |
010cbe546627dbabb2fd3e61148a65725a9ffe6df3466b8b2ae8b5f0c9346cdd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/4.0.2 CPython/3.11.4
|
Release files / py40kie-0.2.2-py3-none-any.whl
| Download URL | py40kie-0.2.2-py3-none-any.whl |
|---|---|
| Size | 6.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
82d264ad45518101138d036158cd648cf3c601031ff124e06abfd26d34e05751
|
|
BLAKE2b-256 checksum How to use checksums |
9fa85af83e714384f5801dbe38724443c66bc0c69bcd7cc9960f7326f5786267
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/4.0.2 CPython/3.11.4
|
Security for py40kie 0.2.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.