Your agent already ran the tests. Let that run be the check.

shipcheck runs your checks on your machine, natively in a sandbox or as your GitHub Actions workflows in containers, keeps the result for that exact git tree, and posts the required checks. A PR whose tree was already tested gets its checks at once from the stored result. The checks shipcheck runs use none of your GitHub Actions minutes, so those can go to releases and deploys. Your workflows still run on GitHub when a commit lands on main, as a second check.

$ brew install gabrielkoerich/tap/shipcheck

Homebrew and the install script install the release binary, signed and notarized on macOS. Then run shipcheck init in your repository. Quickstart

Fix parser on empty input #482, fix-parser into main
  • shipcheck/testRequired, success
  • shipcheck/lintRequired, success
  • shipcheckPassed, tree already tested
Squash and mergeAll checks have passed

How it works

  1. The agent runs shipcheck run instead of its tests. shipcheck tests the working copy as it is, in its own clone, and the agent commits it with shipcheck commit. The commit's tree already ran, so its check needs no new run. A commit nobody tested starts a background run from the pre-push hook when you push it, or from the post-commit hook with on = ["push", "commit"].
  2. shipcheck reads what to run from main. shipcheck.toml and the workflows come from the default branch the remote reports, never from the branch, so a PR cannot change what checks it.
  3. It runs the checks in a warm, clean checkout. A copy-on-write clone of the tree keeps the build caches. In host mode the commands run natively in an OS sandbox. In act mode act runs the workflow jobs in Docker, or a job you pick runs in a colima VM of its own, and markers added to shipcheck's own copy of each workflow report every job.
  4. It keeps the result for the tree. The key is the git tree plus the config, the workflows, the tool versions and the images, so a rebase or a squash with the same tree needs no new run.
  5. The PR gets its checks. shipcheck posts one check per job, such as shipcheck/test, as GitHub Actions does, and branch protection requires them. GitHub still runs your workflows on main after the merge.

How long a run takes, against GitHub Actions on the same commits.

What the repository owner sets up

One file says which checks a PR must pass. shipcheck init writes it from your workflow jobs.

# shipcheck.toml
runner = "host"
on = ["push", "commit"]

[host.checks]
test = "cargo test"
clippy = "cargo clippy --all-targets -- -D warnings"
  • shipcheck init writes the file, installs the hooks, and offers to run hosted Actions only on main.
  • The shipcheck App posts the checks. Install it on the repository. shipcheck init and shipcheck install sign each machine in. Post the checks
  • A ruleset requires the job checks on main, so a PR merges only after every job passes. shipcheck init can create it with your gh login.
  • Each teammate runs shipcheck install once per clone.

What it stops, and what it does not

It stops

  • An agent that reports a pass it never ran. Only shipcheck posts the check, from runs it started.
  • A PR that edits its workflows or shipcheck.toml to skip work.
  • A pass from before main's config changed.
  • A pass from files that were never committed.

It does not stop

  • An agent that deletes or weakens a test. Tests are part of the PR, so review them.
  • Differences between this machine, or act's containers, and GitHub's runners. The hosted run on main catches them.
  • In act mode, jobs that act cannot run, such as macOS jobs or a job that mounts a loop device.

What a green check proves and what a job can reach