Reference
Exit codes
Three exit codes, so scripts can tell “not ready” apart from “couldn't check”.
0
Ready
No check failed. Warnings and skipped checks are allowed.
1
Not ready
At least one check failed. The report says which, and why.
2
Shipcheck error
Shipcheck couldn't run: an invalid config file, an unknown flag, a missing directory, or an interrupt.
Gating a deploy
bash
$ shipcheck && echo "Ready to deploy"The deploy only runs on exit code 0.
Telling failures apart
deploy.sh
shipcheckcase $? in 0) ./deploy.sh ;; 1) echo "Not ready to ship, fix the failures above." ; exit 1 ;; *) echo "Shipcheck could not run." ; exit 2 ;;esacWarnings and severity
Warnings never change the exit code. To make a warning block shipping, set its severity to error in .shipcheck.yml; to stop a failure from blocking, set it to warn.
yaml
severity: ci: error # missing CI now exits 1 git_clean: warn # uncommitted changes no longer exit 1Found a mistake? Edit this page on GitHub