Make the CI gate work on Gitea by building instead of bind-mounting
Tests / vet + fmt + tests (pull_request) Successful in 27s
Tests / vet + fmt + tests (push) Successful in 6s

This commit was merged in pull request #1.
This commit is contained in:
2026-09-01 20:33:04 +02:00
parent 05dc042e49
commit d44c941a92
5 changed files with 26 additions and 25 deletions
+8 -4
View File
@@ -482,7 +482,6 @@ Source is bind-mounted; build caches persist in the `gocache` volume.
```sh
docker compose run --rm test # run tests
docker compose run --rm ci # vet + format check + tests
docker compose run --rm cover # tests with coverage
docker compose run --rm bench # benchmarks
docker compose run --rm build # compile the library
@@ -497,9 +496,14 @@ docker compose run --rm --user "$(id -u):$(id -g)" fmt # gofmt -w .
docker compose run --rm --user "$(id -u):$(id -g)" tidy # go mod tidy
```
Every pull request runs `docker compose run --rm ci` against both the latest and
the lowest supported Go, and must pass before it can be merged. `docker build .`
runs the same vet and tests locally.
Every pull request runs `docker build .` against both the latest and the lowest
supported Go, and must pass before it can be merged. That build is the whole
gate — vet, format check and tests — so run it locally before pushing:
```sh
docker build . # latest
docker build --build-arg GO_VERSION=1.22.12 . # lowest supported
```
Tests run against the latest Go by default. Set `GO_VERSION` to check the lowest
supported version too: