Skip to content

ManualConfiguration

Check fields

Use these fields to tell Berrit which tests a change needs and whose result to wait for.

If you’re deciding whether to test a revision or the train candidate, How checks work explains the three stages.

Put one [[check]] table per check in checks.toml at the repository root. Berrit reads this file and berrit.toml together from the tip of the target branch. Without checks.toml, there are no external checks.

Every check needs name, on, paths and timeout.

Field Value
name Give each check a unique name (1–100 characters). Berrit reserves review and no-conflicts. For a job GitHub starts, copy the displayed name, including any matrix suffix. Give different jobs different names if they run on the same commit. Berrit combines results reported under the same name, so one green job can still leave the check waiting or failed.
on Choose one or more stages. Use "push" to check a revision when you send it, "approved" to check it after approval, and "train" to check the candidate commit.
paths One or more glob patterns, starting at the repository root. The check applies when any changed file matches a pattern. Use ["**"] for all files.
timeout How long Berrit waits, from "1m" to "24h". For an existing job, count from when Berrit expects its result, so allow for time in the CI queue. For a workflow Berrit dispatches, the clock starts when Berrit starts the run.
required Defaults to true. Set it to false to show the result without holding up landing.

If you’re trying a new test and want to see its results first, start with a push check and required = false. Once the config is on the target branch, send a revision that touches a matching file. In Checks, follow Details to confirm you got the job you expected. Make the check required when you’re ready for its failures to hold up a change.

If you want Berrit to start a workflow, set workflow to the filename inside .github/workflows/. This uses the GitHub App automatically. Berrit checks the result of the entire run. Set up a dispatched workflow.

If GitHub already starts the job, set app = "github@apps.berrit" and omit workflow. Berrit waits for that app to report the matching job name on the expected commit. Use an existing CI job.

For CI outside GitHub, you need an integration that runs the job and sends the result back as a Berrit app. Use the registered app’s address and the check name it reports. Berrit matches both to the commit it asked the app to test. The App field under Settings → Configuration → Edit shows the apps available to the repository. Writing an address in TOML doesn’t register an app. If yours is missing, ask your Berrit operator to provision it before making the result required.

If your old berrit.toml still has [[check]] tables, move them into checks.toml beside it. Leaving them in the old file makes the configuration invalid and blocks landing. Review settings and train settings stay in berrit.toml. Configure berrit.toml

With this line inside a check, Berrit looks for a result when a change touches either directory, including subdirectories. The on stages still apply.

checks.toml (inside [[check]])
paths = ["src/**", "tests/**"]

A change that only updates package-lock.json at the repository root would skip that check. If a dependency update can break the build, include the lockfile in paths, or leave ["**"] in place until you know what you can safely skip. Patterns start at the root. For example, *.rs matches Rust files at the top level and **/*.rs matches them anywhere.

If Berrit is waiting for an existing GitHub job, GitHub’s workflow triggers still decide when it runs. Make sure they allow the job to run for every change that matches the Berrit check.

If you already deploy after a push to main, keep that workflow on GitHub. Use a landing step when the deployment itself must succeed before Berrit moves the target branch. In that case, give the dispatched check a revert workflow alongside its workflow. It must be required and use on = ["train"] alone. Leave revert out of ordinary builds and tests.

Suppose deploy.yml brings an environment up to the version it checks out. With workflow = "deploy.yml" and revert = "deploy.yml", Berrit first waits for the train’s required tests, then runs the deployment on the candidate. If a landing step fails, Berrit waits for the steps to finish and runs their revert workflows on the target branch’s current commit. Reusing the same file works if deploying that older commit restores the environment. Otherwise, name a separate workflow that does the cleanup.