Skip to main content

workshopify

Skeleton and scaffolding for template-rendered, notebook-based workshop repositories.

A workshop repo declares everything mechanical in [tool.workshopify] tables in its pyproject.toml, and workshopify does the rest:

Command Does
workshopify render Re-render templated values and assets in place
workshopify check Report stale rendered values or assets; exit 1 if any
workshopify generate Generate the notebooks and notes from src/
workshopify build Assemble the published workshop tree into its branch worktree
workshopify set <key> <value> Set a [tool.workshopify.params] value and re-render
workshopify worktree <branch> Prepare a branch worktree without building

Configuration

Every command finds its workshop by walking up from the working directory to the nearest pyproject.toml with a [tool.workshopify] table. That file's directory is the repo root, and every path below is relative to it. Keys are kebab-case, and every one of them has a default, so a table with nothing to say may be left out entirely.

[tool.workshopify]

Key Default Does
context none Names the context module: the workshop's procedural half, whose module-level names become the namespace the templating runs in, and whose optional ASSETS dict maps a path in the published tree to the repo file copied there verbatim. Omit it for a workshop that templates nothing and declares no assets; a module that is named must exist.
params {} The workshop's own values, handed to the context module as params and rewritten in place by workshopify set. The keys are whatever that module reads.

[tool.workshopify.render]

Key Default Does
files [] Glob patterns naming the files render rewrites in place and check verifies. A pattern that matches nothing is an error — a typo'd glob would otherwise render nothing, forever, in silence — while declaring no patterns at all is a workshop that templates nothing.

[tool.workshopify.notebooks]

Key Default Does
src "src" The directory holding the py:percent sources. Which notebooks exist is decided by the [[tool.ipynb-scrubber.files]] entries; this only says where each one's source is read from, as <src>/<stem>.py.

[tool.workshopify.build]

Key Default Does
branch "workshop" The branch the published tree is assembled onto, in a worktree at <root>/<branch>. build writes that tree and prints how to review and push it; it commits nothing itself.
include [] Repo files and directories copied into the published tree at the same relative path. Entries must be relative and free of ...
keep-tables ["project", "tool.uv"] Dotted paths kept in the participants' derived pyproject.toml; everything else is dropped. A path names its whole subtree.
drop-keys [] Dotted paths carved back out of what keep-tables kept — the workspace wiring under [tool.uv], say, which participants have no checkout to point at.

A path in either list that matches nothing in the repo's own pyproject.toml is an error rather than a no-op, as is a path listed alongside one of its own descendants: both would otherwise ship a silently wrong pyproject.

What [tool.workshopify] does not say

Some of the published tree comes from places no key names:

  • static/ at the repo root is an overlay — every file under it is copied to the same path in the published tree, with the static/ prefix stripped.
  • [tool.jupytext] and [tool.ipynb-scrubber] are read as those tools define them, so the notebook formats, the scrub markers, and the set of generated notebooks and notes are configured there and not here.
  • uv.lock is derived from the repo's own lock, re-resolved offline, so participants get the versions contributors develop against — and a repo that has never run uv lock has nothing to build from.

Status

Extracted from a working workshop repository and being generalised. The configuration contract and command surface are still subject to change.

Download files

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

Source Distribution

workshopify-0.2.1.tar.gz (96.3 kB view details)

Uploaded Source

Built Distribution

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

workshopify-0.2.1-py3-none-any.whl (45.4 kB view details)

Uploaded Python 3

File details

Details for the file workshopify-0.2.1.tar.gz.

File metadata

  • Download URL: workshopify-0.2.1.tar.gz
  • Upload date:
  • Size: 96.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for workshopify-0.2.1.tar.gz
Algorithm Hash digest
SHA256 1b5af4943d0f245b562942df7c2c99c2a0dea0df2e3a35be545e155ec0977bf1
MD5 ab736cb950338ffd17540c00f58aa6ce
BLAKE2b-256 520189f7aac778712d1e8fcb2a3b242b8632402cbdc1b2157e5b5e6810b8d0a1

See more details on using hashes here.

Provenance

The following attestation bundles were made for workshopify-0.2.1.tar.gz:

Publisher: release.yml on jkeifer/workshopify

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file workshopify-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: workshopify-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 45.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for workshopify-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 dd1d3c03e4396bf6d0ecab8a871555886d9683765cd9c95cab951e1210b05d8a
MD5 09e2822646284b37d695761a5506fa0e
BLAKE2b-256 f1409fff2b24e997baf207bdebbfdae248cbff9c3902909347416662b89f64b7

See more details on using hashes here.

Provenance

The following attestation bundles were made for workshopify-0.2.1-py3-none-any.whl:

Publisher: release.yml on jkeifer/workshopify

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.2.2

2 files

This release

0.2.1 This release

2 files

0.2.0

2 files

0.1.0

2 files

Supported by

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