Workspace tools for Gleam monorepos.Derived from gleam.toml.
Gleam builds, tests, and publishes one package at a time. Trellis runs those commands across your packages and manages their changelogs and versions.
$curl --proto '=https' --tlsv1.2 -LsSf https://github.com/tylerbutler/trellis/releases/latest/download/trellis-gleam-installer.sh | shlat_core (1.2.0)
lat_mid (0.5.0)
└─ lat_core
lat_cli (0.3.1)
├─ lat_core
└─ lat_mid
package_a (0.0.0)
└─ lat_cliThe glue this replaces.
The lattice inventory records the bash loops, YAML blocks, and duplicated configuration below. Each row is workspace information that was maintained by hand.
| File | What's maintained by hand | What can drift |
|---|---|---|
justfile | The package list, in topological order, as a space-separated string | A new package is silently excluded from every recipe |
justfile | ~15 near-identical for pkg in … bash loops | Copy-paste drift between recipes; strictly serial execution |
.changie.yaml | One config block per package: label, key, changelog path, version regex | A forgotten block means a package can't be versioned or released |
publish.yml | A hand-written copy of the path dependency graph | Nothing verifies it when a package gains a dependency |
release.yml | 25 lines of inline sed/grep patching locked versions | Version edits depend on regexes embedded in CI YAML |
Trellis derives the information behind each row from gleam.toml, a file format the ecosystem already uses.
Configure nothing that can be derived.
Verify anything that must be duplicated.
# The table's presence marks the workspace root.# Every key is optional. Omit members to auto-discover from git.[tools.trellis]members = ["packages/*", "examples/*"]# Exclusions are scoped by task. `@release` covers changelog,# versioning, tagging, publishing, and release CI.exclude = { docs = ["examples/*"], "@release" = ["examples/*"] }
[tools.trellis.tasks.lint]command = "gleam run -m glinter"
[tools.trellis.publish]exact_tag_format = "{name}-v{version}"From that, trellis computes:
- Package discovery and dependency order. Trellis includes directories that match your member patterns and contain a package manifest, subject to membership and task exclusions.
- Change impact.
--since origin/mainselects packages with changed files. Add--with-dependentsto include packages that depend on them. - Publish order and path-dep rewrites. Dependencies publish first, and path references become Hex versions automatically.
- Package tags and configuration checks.
trellis doctorreports problems and exits non-zero on errors.
Opinionated, but modular.
Trellis records each change as a TOML fragment, derives version bumps from fragment kinds, and tags each release per package. You choose when to tag and when to publish. Start with task running and keep your existing changelog tool and CI. Add trellis's changelog, versioning, or publishing commands when you need them.
Just the task runner
Read the task-running guide →run,exec,list, andgraphneed no configuration at all, because members are auto-discovered from git.Add changelogs and versioning
Fragments,
Read the versioning guide →version plan, andversion applymanage version bumps and changelogs locally or in your existing CI.Add publishing
Read the publishing guide →tagrecords releases;publishuploads packages to Hex in dependency order.The full pipeline
Read the CI recipes →ci,changelog check, andrelease prgenerate matrices, check changelog coverage, and prepare release pull requests for GitHub Actions.
One workspace. Different task sets.
Examples, benchmarks, and internal tools can remain workspace members for builds, tests, and graphing without needing generated docs or a release on Hex.
exclude gives each built-in or custom task its own member-path globs. The reserved @release key covers changelogs, versioning, tags, publishing, and release CI.
| Package path | build / test | docs | release |
|---|---|---|---|
packages/* | included | included | included |
examples/* | included | excluded | excluded |
lat_core hex
lat_mid hex
lat_cli hexpackage_a, the package in examples/, still appears in trellis list, graph, exec, and tasks that do not exclude it. Only the configured task sets change.Checks for drift.
trellis doctor checks locked versions, changelogs, tags, and toolchain pins against the workspace. It reports each problem and exits non-zero on errors; warnings do not fail the command.
checked: member globs resolve and every package has a parseable gleam.toml
checked: path dependencies stay inside the workspace; graph is acyclic
checked: manifest.toml locked versions match workspace-internal gleam.toml versions
checked: pinned git dependency SHAs remain reachable from their tracked refs (advisory)
checked: each releasable package's version is not behind its CHANGELOG
...
warning: package `lat_core` has changelog history that trellis has not batched yet; it will be adopted on the next release
...
ok: 4 package(s) (1 workspace, 0 git_only, 3 hex), 3 warning(s)trellis doctor --fix imports its existing changelog history.Install a prebuilt binary.
Install trellis without a Rust toolchain. Release archives include SLSA build provenance attestations. Gleam tasks still need Gleam and the tools required by your chosen target.
- Shell (Linux, macOS)
$curl --proto '=https' --tlsv1.2 -LsSf https://github.com/tylerbutler/trellis/releases/latest/download/trellis-gleam-installer.sh | sh- Homebrew
$brew install tylerbutler/tap/trellis- mise (pin it in mise.toml)
$mise use "github:tylerbutler/trellis@1.7.0"- From source
$cargo install --git https://github.com/tylerbutler/trellis
On Windows, use the PowerShell installer. To keep CI on a specific release, pin the installer URL. Run trellis doctor inside your Gleam repository to check it. Use trellis init when you want to configure workspace settings; the configuration guide covers what it writes.