Skip to main content

A Static Revue Generator.

Project description

Crieur — A Static Site Generator from Stylo sources.

Either for a magazine or a blog or whatever you want to do! Everything is configurable at the template-level.

Run

uv run --with crieur crieur stylo <stylo-corpus-id-1> <stylo-corpus-id-2> …
uv run --with crieur crieur generate serve --title PHLiT

Help

Commands

usage: crieur [-h]  ...

options:
  -h, --help   Show this help message and exit

Available commands:
  
    version    Return the current version.
    init       Generate the default TOML configuration file.
    build      Download Stylo sources and generate the website.
    generate   Generate a new revue website.
    stylo      Initialize a new revue to current directory from Stylo.
    templates  Fetch a theme from a git repository.
    serve      Serve an HTML book from `repository_path`/public or current
               directory/public.

Command: init

usage: crieur init [-h] [--name NAME]

options:
  -h, --help       show this help message and exit
  --name, -n NAME  Custom name for the TOML file (default: site.toml).

Command: build

usage: crieur build [-h] config_path

positional arguments:
  config_path  Path to the TOML configuration file.

options:
  -h, --help   show this help message and exit

Command: generate

usage: crieur generate [-h] [--title TITLE] [--base-url BASE_URL]
                       [--extra-vars EXTRA_VARS] [--target-path TARGET_PATH]
                       [--source-path SOURCE_PATH]
                       [--statics-path STATICS_PATH]
                       [--templates-path TEMPLATES_PATH] [--csl-path CSL_PATH]
                       [--without-statics] [--without-search] [--blog]
                       [--flat] [--feed-limit FEED_LIMIT] [--exports EXPORTS]
                       [--linkable-blocks]

options:
  -h, --help            show this help message and exit
  --title, -t TITLE     Title of the website (default: Crieur).
  --base-url BASE_URL   Base URL of the website, ending with / (default: /).
  --extra-vars EXTRA_VARS
                        stringified JSON extra vars passed to the templates.
  --target-path TARGET_PATH
                        Path where site is built (default: /public/).
  --source-path SOURCE_PATH
                        Path where stylo source were downloaded (default:
                        /sources/).
  --statics-path STATICS_PATH
                        Path where statics are located (default:
                        @crieur/statics/).
  --templates-path TEMPLATES_PATH
  --csl-path CSL_PATH   Path to the CSL applied for bibliography (default:
                        @crieur/styles/apa.csl).
  --without-statics     Do not copy statics if True (default: False).
  --without-search      Do not generate search page if True (default: False).
  --blog, -b            Use the built-in blog theme if True, overrides
                        statics/templates options (default: False).
  --flat, -f            Use a flat tree structure for Article URLs if True
                        (default: False, except for blog).
  --feed-limit FEED_LIMIT
                        Number of max items in the feed (default: 10).
  --exports, -e EXPORTS
                        Kind of exports you want to expose, comma separated
                        (pdf, xml-tei, etc).
  --linkable-blocks     Add anchors to paragraphs and headers if True
                        (default: False).

Command: serve

usage: crieur 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: crieur stylo [-h] [--pages PAGES] [--exports EXPORTS]
                    [--stylo-instance STYLO_INSTANCE]
                    [--stylo-export STYLO_EXPORT] [--force-download]
                    [stylo_ids ...]

positional arguments:
  stylo_ids             Corpus ids from Stylo, separated by commas.

options:
  -h, --help            show this help message and exit
  --pages, -p PAGES     Corpus id from Stylo to load satellite pages (contact,
                        etc).
  --exports, -e EXPORTS
                        Kind of exports you want to download, comma separated
                        (pdf, xml-tei, etc).
  --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).
  --force-download      Force download of sources from Stylo (default: False).

Command: templates

usage: crieur templates [-h] [--repo-url REPO_URL] [--source-path SOURCE_PATH]
                        [--quiet]

options:
  -h, --help            show this help message and exit
  --repo-url REPO_URL   Repository URL, ending with / (default:
                        https://gitlab.huma-num.fr/ecrinum/crieur-templates/).
  --source-path SOURCE_PATH
                        The path within the git repository to the theme files
                        (e.g.: blogs/blog-purple).
  --quiet, -q           Do not prompt for file overrides if True (default:
                        False).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

crieur-4.1.0.tar.gz (720.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

crieur-4.1.0-py3-none-any.whl (730.2 kB view details)

Uploaded Python 3

File details

Details for the file crieur-4.1.0.tar.gz.

File metadata

  • Download URL: crieur-4.1.0.tar.gz
  • Upload date:
  • Size: 720.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.28.1

File hashes

Hashes for crieur-4.1.0.tar.gz
Algorithm Hash digest
SHA256 acb72548a223abe5eeff5fca4dc0ee7979f622fd675d1fcfecde8b64096a2e13
MD5 25bb43c58e815ff454e55f125b81d765
BLAKE2b-256 da19785649589951e31897aed85c19e02b65b8514b26fce9bd0c67af6baa6926

See more details on using hashes here.

File details

Details for the file crieur-4.1.0-py3-none-any.whl.

File metadata

  • Download URL: crieur-4.1.0-py3-none-any.whl
  • Upload date:
  • Size: 730.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.28.1

File hashes

Hashes for crieur-4.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 227a9bfa5789ea6ab59dd5163a616131ea468012c21228cd9424a7fc94553db2
MD5 359169c764765119502a5403691c4df9
BLAKE2b-256 db8db27e22ba3dffed5f73b46b56f9f43839dc861228e9812f2198a1bc17d34b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page