Skip to main content
This page shows how to build your installer on a build server, mainly with Bach’s GitHub Action. If you’d rather have a complete release workflow written for you, use one-click releases instead.

Build on every tag

This workflow builds and publishes a release whenever you push a tag like v1.4.0:
.github/workflows/release.yml
The tag sets the app version: v1.4.0 builds version 1.4.0, so you don’t have to edit bach.toml for each release.

Only build, don’t publish

.github/workflows/build.yml
The action works on Windows, macOS and Linux runners. It runs bach doctor and then bach build. Build on windows-latest so your setup file gets your icon; elsewhere it keeps Bach’s.

Inputs

For compare to comment on pull requests, the job needs pull-requests: write.

Outputs

Sign in CI

Getting cert.pfx onto the runner from a secret is up to your workflow. The signature is added before latest.json is written, so the feed’s checksum matches the signed file. See Signing.

Secrets for protected apps and signed feeds

If your app uses an access key or a signed feed, pass the secrets as environment variables:

Pin the action

Other CI systems

Install bach in the job and call it as you would locally:
bach exits with a non-zero code and a readable message when anything is wrong. --strict also fails on warnings, and --json prints a machine-readable result. If the runner can’t download from GitHub, put bach-setup.exe next to bach, or pass --runtime <path>. Set BACH_NO_DOWNLOAD to forbid downloads. See Environment variables.