Pressoir
Documentation complète : https://pressoir.org/
Utilisation rapide
- Installer uv : https://docs.astral.sh/uv/getting-started/installation/#standalone-installer
- Se placer dans le dossier contenant les
textes - Construire le livre :
uv run --with pressoir pressoir build serve - Se rendre sur http://127.0.0.1:8000 pour visualiser le livre
Optionnellement, générer un PDF du livre :
- Lancer :
uv run --with pressoir pressoir export - Récupérer le PDF dans
public/book.pdf
À partir d’un corpus Stylo
- Installer uv : https://docs.astral.sh/uv/getting-started/installation/#standalone-installer
- Se placer dans un nouveau dossier
- Récupérer les textes :
uv run --with pressoir pressoir stylo <corpus-id> - Construire le livre :
uv run --with pressoir pressoir build serve - Se rendre sur http://127.0.0.1:8000 pour visualiser le livre
Installation
Pré-requis : Python3.8+
Installer et activer un environnement virtuel :
$ python3 -m venv venv
$ source venv/bin/activate
Installer les dépendances :
$ make install
Initialiser un livre
Par exemple :
$ pressoir init --repository-path=../fia --collection sp
ou
$ pressoir init --repository-path=../12-editionscritiques --collection pum
Note : si la destination n’existe pas ou n’a pas de dossier textes,
une coquille complète du livre est créée.
Par exemple :
$ mkdir livre-test
$ cd livre-test
$ python3 -m venv venv
$ source venv/bin/activate
$ pip install pressoir
$ pressoir init --collection=sp
Construire un livre
$ pressoir build --repository-path=../fia-en
Avec ../fia-en qui est le chemin vers le dépôt du livre.
En bonus, il est possible de passer un chapitre particulier pour ne reconstruire que lui :
$ pressoir build --repository-path=../fia-en --chapter=chapter1
Si vous êtes en local / développement, il faut passer l’option --local
pour que les liens de parcours du livre fonctionnent.
Servir un livre
$ pressoir serve --repository-path=../fia-en
Avec ../fia-en qui est le chemin vers le dépôt du livre qui a été construit.
Générer les md+tex+pdf d’un livre
Expérimental : il est possible avec la commande pressoir export de générer des fichiers markdown, tex et pdf à partir des sources. Ils vont être créés dans public/book.{md|tex|pdf}.
Il est nécessaire d’avoir (xe)latex pour effectuer cette génération.
Help
Commands
usage: pressoir [-h] ...
options:
-h, --help Show this help message and exit
Available commands:
version Return the current version of pressoir.
init Initialize a new book to `repository_path` or current directory.
docs Generate documentation with pressoir itself. #SoMeta
build Build a book from `repository_path` or current directory.
export Generate a single md+tex+pdf file from `repository_path` or
current directory.
serve Serve an HTML book from `repository_path`/public or current
directory/public.
stylo Initialize a new book to current directory from Stylo.
Command: init
usage: pressoir init [-h] [--repository-path REPOSITORY_PATH]
[--collection {pum,sp,blank}]
options:
-h, --help show this help message and exit
--repository-path REPOSITORY_PATH
Absolute or relative path to book’s sources (default:
current).
--collection, -c {pum,sp,blank}
Name of the collection (default: blank).
Command: docs
usage: pressoir docs [-h] [--target-path TARGET_PATH]
options:
-h, --help show this help message and exit
--target-path TARGET_PATH
Command: build
usage: pressoir build [-h] [--repository-path REPOSITORY_PATH]
[--csl-path CSL_PATH] [--target-path TARGET_PATH]
[--templates-folder TEMPLATES_FOLDER]
[--chapter CHAPTER] [--keep-statics] [--verbose]
options:
-h, --help show this help message and exit
--repository-path REPOSITORY_PATH
Absolute or relative path to book’s sources (default:
current).
--csl-path CSL_PATH Path to .csl file (default: Pandoc’s default).
--target-path TARGET_PATH
Where the book will be built (default:
`repository_path`/public).
--templates-folder TEMPLATES_FOLDER
Folder with header.html/footer.html for before/after
inclusion.
--chapter, -c CHAPTER
Specify a given chapter id (e.g. `chapter1`).
--keep-statics Do not override the statics with regular ones
(default: False).
--verbose, -v Display more informations during the build (default:
False).
Command: export
usage: pressoir export [-h] [--repository-path REPOSITORY_PATH]
[--template-path TEMPLATE_PATH] [--csl-path CSL_PATH]
[--target-path TARGET_PATH] [--verbose]
options:
-h, --help show this help message and exit
--repository-path REPOSITORY_PATH
Path to book’s sources (default: current).
--template-path TEMPLATE_PATH
Path to .tex template (default: Pandoc’s default).
--csl-path CSL_PATH Path to .csl file (default: Pandoc’s default).
--target-path TARGET_PATH
Where the book will be built (default:
`repository_path`/public).
--verbose, -v Display a lot of informations, useful for debugging.
Command: serve
usage: pressoir serve [-h] [--repository-path REPOSITORY_PATH] [--port PORT]
options:
-h, --help show this help message and exit
--repository-path REPOSITORY_PATH
Absolute or relative path to book’s sources (default:
current).
--port, -p PORT Port to serve the book from (default=8000)
Command: stylo
usage: pressoir stylo [-h] [--stylo-instance STYLO_INSTANCE]
[--stylo-export STYLO_EXPORT] [--from-scratch]
[--keep-metadata]
stylo_id
positional arguments:
stylo_id Corpus id from Stylo.
options:
-h, --help show this help message and exit
--stylo-instance STYLO_INSTANCE
Instance of Stylo (default: stylo.huma-num.fr).
--stylo-export STYLO_EXPORT
Stylo export URL (default: https://export.stylo.huma-
num.fr).
--from-scratch Do not ask to override local files (default: False).
--keep-metadata Do not override the `livre.yaml` metadata file
(default: False).
Metadata
Release files for pressoir 4.12.1
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 |
|---|---|---|---|---|
| pressoir-4.12.1.tar.gz | 7.8 MB | Without provenance | Details for pressoir-4.12.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pressoir-4.12.1-py3-none-any.whl | Python 3 | none | any | Details for pressoir-4.12.1-py3-none-any.whl |
Total release size: 15.7 MB
Release files / pressoir-4.12.1.tar.gz
| Download URL | pressoir-4.12.1.tar.gz |
|---|---|
| Size | 7.8 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
de074213a58c08faa21110d9fc4f8b7290308ebe28be5df8802d6fc64b909598
|
|
BLAKE2b-256 checksum How to use checksums |
58aaa70238da2f83809308c6cfd94d391c7373c825dae57d20e5ed245b56db30
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Hatch/1.17.0 {"ci":null,"cpu":"arm64","distro":{"name":"macOS","version":"27.0.1"},"implementation":{"name":"CPython","version":"3.14.2"},"installer":{"name":"hatch","version":"1.17.0"},"openssl_version":"OpenSSL 3.5.4 30 Sep 2025","python":"3.14.2","system":{"name":"Darwin","release":"27.0.0"}} HTTPX2/2.5.0
|
Release files / pressoir-4.12.1-py3-none-any.whl
| Download URL | pressoir-4.12.1-py3-none-any.whl |
|---|---|
| Size | 7.9 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
38a8b99b7b2ac1469f68a55481e12a1187d13da2e05d0b3800c2727889497874
|
|
BLAKE2b-256 checksum How to use checksums |
48e0bac501ad12ae00599001937ef967f8e57daf23a338c471b367b30337b934
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Hatch/1.17.0 {"ci":null,"cpu":"arm64","distro":{"name":"macOS","version":"27.0.1"},"implementation":{"name":"CPython","version":"3.14.2"},"installer":{"name":"hatch","version":"1.17.0"},"openssl_version":"OpenSSL 3.5.4 30 Sep 2025","python":"3.14.2","system":{"name":"Darwin","release":"27.0.0"}} HTTPX2/2.5.0
|
Security for pressoir 4.12.1
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.