Files
webhooker/script/fmt-check
T
sneak 537374e4cc
check / check (push) Waiting to run
Deploy main eacf1e7 to prod
Replaces #559, which conflicted.

Model: opus-5-5
2026-10-25 01:55:36 +00:00

20 lines
467 B
Bash
Executable File

#!/bin/sh
# script/fmt-check: check formatting (read-only). Same scope as
# script/fmt, but fails instead of writing. --no-cache because a cached
# check is a check that did not run.
set -eu
ROOT="$(cd "$(dirname "$0")/.." && pwd -P)"
main() {
cd "$ROOT"
if [ -n "$(gofmt -s -l .)" ]; then
echo "gofmt needed on:"
gofmt -s -l .
exit 1
fi
docker build --no-cache --target markdown-check --output type=cacheonly .
}
main "$@"