Skip to content

Installation

Prebuilt binaries need no Rust toolchain. Releases include SLSA build provenance attestations and binaries for Linux (glibc) and macOS on x86_64 and aarch64, and Windows on x86_64.

To run Gleam tasks, install Gleam and the tools your target needs, such as Erlang/OTP or a JavaScript runtime.

On Linux and macOS:

Terminal window
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/tylerbutler/trellis/releases/latest/download/trellis-gleam-installer.sh | sh

On Windows:

Terminal window
powershell -ExecutionPolicy Bypass -c "irm https://github.com/tylerbutler/trellis/releases/latest/download/trellis-gleam-installer.ps1 | iex"
Terminal window
brew install tylerbutler/tap/trellis

Use mise’s github backend to install trellis and record its version in mise.toml. Commit that file to share the pin with your team and CI:

Terminal window
mise use "github:tylerbutler/trellis@1.7.0"

The crate is named trellis-gleam on crates.io; the installed binary is trellis:

Terminal window
cargo install trellis-gleam
# or straight from the repository:
cargo install --git https://github.com/tylerbutler/trellis

Run these commands inside your Gleam repository. Trellis walks up to the first gleam.toml with a [tools.trellis] table, or uses the git repository root when no manifest has one. This excerpt uses the example workspace:

Terminal window
$ trellis --version
trellis 1.7.0
$ trellis doctor
checked: member globs resolve and every package has a parseable gleam.toml
checked: path dependencies stay inside the workspace; graph is acyclic
...
ok: 4 package(s) (1 workspace, 0 git_only, 3 hex), 3 warning(s)

The example’s warnings concern existing changelog history, which trellis doctor --fix can import. For workspace settings, use the configuration guide.

The installer URLs above resolve latest. To pin a specific version, replace latest/download with download/v<version>:

Terminal window
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/tylerbutler/trellis/releases/download/v1.7.0/trellis-gleam-installer.sh | sh

Prebuilt archives for every target are on the releases page.

The binary supplies completion candidates as you type, using its current flags and the package names, task names, and changelog kinds in your workspace.

Add one line to your shell’s startup file:

~/.bashrc
eval "$(trellis completions bash)"
# ~/.zshrc (after compinit)
eval "$(trellis completions zsh)"
# ~/.config/fish/config.fish
trellis completions fish | source
# ~/.elvish/rc.elv
eval (trellis completions elvish | slurp)
# $PROFILE (PowerShell)
trellis completions powershell | Out-String | Invoke-Expression

Evaluate the snippet on startup. Saving its output to a completions directory can leave an incompatible script after a trellis upgrade.

Completing after -C uses the current directory, not the directory you passed. --bump completes only the three bare levels, not the <pkg>=<level> form.

trellis.1 and a page per subcommand ship inside the release archives under man/. Neither the shell installer nor the Homebrew formula installs them automatically, so point man at the extracted archive or install them yourself:

Terminal window
sudo mkdir -p /usr/local/share/man/man1
sudo cp man/*.1 /usr/local/share/man/man1/
man trellis
man trellis-run

Everything in those pages is also on the CLI reference page.