fix(repo):统一发布健康与只读质量门禁
bat-rust / Build and test Rust (push) Canceled after 0s
bat-rust / Build and test Go API (push) Canceled after 0s

This commit is contained in:
2026-09-13 22:09:44 +08:00
parent 32fc64fa83
commit c17904ee1c
25 changed files with 869 additions and 184 deletions
+23
View File
@@ -223,6 +223,16 @@ jobs:
source /var/lib/act_runner/env.sh
make test-go-api
- name: Check Go formatting
shell: bash
run: |
set -euo pipefail
source /var/lib/act_runner/env.sh
files="$(git ls-files '*.go')"
test -n "${files}"
test -z "$(gofmt -l ${files})"
- name: Run Go API vet
shell: bash
run: |
@@ -239,6 +249,19 @@ jobs:
source /var/lib/act_runner/env.sh
go build -o /tmp/bat-api ./cmd/bat-api
- name: Optional Go lint
shell: bash
run: |
set -euo pipefail
source /var/lib/act_runner/env.sh
if command -v golangci-lint >/dev/null 2>&1; then
export XDG_CACHE_HOME="${XDG_CACHE_HOME:-/tmp/bat-xdg-cache}"
golangci-lint run ./...
else
printf 'SKIP optional: Go lint (golangci-lint); reason=command not installed\n'
fi
- name: Run documentation status gate
shell: bash
run: |