Files
simplelog/script/fmt
T
clawbot 7b34edf12e
check / check (push) Failing after 4s
Re-vendor the standard files from sneak/prompts dd4027b (closes #33)
REPO_POLICIES.md, .golangci.yml, the CI workflow and the scripts the
policy keeps identical across repositories are copies of the files at
that commit. .gitignore, .editorconfig and the new .dockerignore are the
canonical files followed by this repository's own entries. The lint
stage moves to the golangci-lint image the policy pins, in the same
commit as .golangci.yml. The format check leaves the lint stage and runs
on the host from script/check, which script/cibuild now runs after
script/bootstrap. The last Dockerfile stage runs script/bootstrap, which
installs goimports with go install at a pinned commit; script/fmt runs
that goimports.

Model: opus-5-5
2026-10-06 13:37:05 +00:00

18 lines
443 B
Bash
Executable File

#!/bin/sh
# script/fmt: format all files (writes) with the goimports that
# script/bootstrap installs. It puts Go's bin directory first on PATH, as
# script/bootstrap does, so it runs that goimports even when the directory
# is not on the caller's PATH.
set -eu
ROOT="$(cd "$(dirname "$0")/.." && pwd -P)"
main() {
cd "$ROOT"
gobin="$(go env GOBIN)"
PATH="${gobin:-$(go env GOPATH)/bin}:$PATH"
goimports -l -w .
}
main "$@"