fix(docker): bump Go version to 1.25.8 (gh#3502) #8731
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| # Guard: go.mod must not contain replace directives — they break `go install`. | |
| # See: https://github.com/steveyegge/gastown/issues/2230 | |
| check-no-replace-directives: | |
| name: Reject go.mod replace directives | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'pull_request' | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Check for replace directives in go.mod | |
| run: | | |
| if grep -qE '^replace\s' go.mod; then | |
| echo "ERROR: go.mod contains replace directives." | |
| echo "" | |
| echo "Replace directives break 'go install github.com/steveyegge/gastown/cmd/gt@latest'." | |
| echo "See: https://github.com/steveyegge/gastown/issues/2230" | |
| echo "" | |
| echo "Found:" | |
| grep -n '^replace' go.mod | |
| echo "" | |
| echo "Remove replace directives before merging to main." | |
| exit 1 | |
| fi | |
| echo "OK: no replace directives in go.mod" | |
| # Guard: gastown no longer supports issues.jsonl — Dolt server is the only backend. | |
| check-no-issues-jsonl: | |
| name: Reject issues.jsonl | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'pull_request' | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Reject issues.jsonl if present | |
| run: | | |
| if [ -f .beads/issues.jsonl ]; then | |
| echo "ERROR: .beads/issues.jsonl must not exist in the repository." | |
| echo "" | |
| echo "Gastown requires a Dolt server — issues.jsonl is no longer supported." | |
| echo "" | |
| echo "To fix, run:" | |
| echo " git rm .beads/issues.jsonl" | |
| echo " git commit --amend" | |
| echo " git push --force" | |
| echo "" | |
| exit 1 | |
| fi | |
| echo "OK: no issues.jsonl found" | |
| test: | |
| name: Test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Go | |
| uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6 | |
| with: | |
| go-version: '1.26' | |
| cache: true | |
| - name: Install ICU4C development headers | |
| run: sudo apt-get install -y libicu-dev | |
| - name: Configure Git | |
| run: | | |
| git config --global user.name "CI Bot" | |
| git config --global user.email "ci@gastown.test" | |
| - name: Install Dolt | |
| run: | | |
| curl -L https://github.com/dolthub/dolt/releases/latest/download/install.sh | sudo bash | |
| - name: Install gotestsum | |
| run: go install gotest.tools/gotestsum@latest | |
| - name: Build | |
| run: go build -v ./cmd/gt | |
| - name: Test with Coverage | |
| run: | | |
| set -o pipefail | |
| gotestsum --format testname --junitfile junit.xml -- -race -short -timeout=10m -coverprofile=coverage.out ./... 2>&1 | tee test-output.txt | |
| - name: Test Report | |
| if: always() | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| PR_NUMBER: ${{ github.event.pull_request.number }} | |
| run: | | |
| python3 .github/scripts/junit-report.py junit.xml "Unit Test Failures" | |
| - name: Upload coverage to Codecov | |
| if: ${{ !cancelled() }} | |
| uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6 | |
| with: | |
| files: coverage.out | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| fail_ci_if_error: false | |
| - name: Upload test results to Codecov | |
| if: ${{ !cancelled() }} | |
| uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6 | |
| with: | |
| files: junit.xml | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| report_type: test_results | |
| fail_ci_if_error: false | |
| lint: | |
| name: Lint | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Set up Go | |
| uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6 | |
| with: | |
| go-version: '1.26' | |
| cache: true | |
| - name: Install ICU4C development headers | |
| run: sudo apt-get install -y libicu-dev | |
| - name: golangci-lint | |
| uses: golangci/golangci-lint-action@1e7e51e771db61008b38414a730f564565cf7c20 # v9 | |
| with: | |
| version: v2.11.4 | |
| args: --timeout=5m | |
| integration: | |
| name: Integration Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Set up Go | |
| uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6 | |
| with: | |
| go-version: '1.26' | |
| cache: true | |
| - name: Install ICU4C development headers | |
| run: sudo apt-get install -y libicu-dev | |
| - name: Configure Git | |
| run: | | |
| git config --global user.name "CI Bot" | |
| git config --global user.email "ci@gastown.test" | |
| - name: Install Dolt | |
| run: | | |
| curl -L https://github.com/dolthub/dolt/releases/latest/download/install.sh | sudo bash | |
| - name: Pre-pull Dolt Docker image | |
| run: docker pull dolthub/dolt-sql-server:1.83.0 | |
| - name: Cache beads (bd) | |
| id: cache-beads-int | |
| uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5 | |
| with: | |
| path: ~/go/bin/bd | |
| key: beads-${{ hashFiles('.github/workflows/ci.yml') }} | |
| - name: Install beads (bd) | |
| if: steps.cache-beads-int.outputs.cache-hit != 'true' | |
| run: go install github.com/steveyegge/beads/cmd/bd@v0.57.0 | |
| - name: Install gotestsum | |
| run: go install gotest.tools/gotestsum@latest | |
| - name: Build gt | |
| run: | | |
| make build | |
| cp gt $(go env GOPATH)/bin/ | |
| - name: Add to PATH | |
| run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH | |
| - name: Integration Tests | |
| run: gotestsum --format testname --junitfile junit-integration.xml -- -tags=integration -timeout=15m -v ./internal/cmd/... | |
| - name: Test Report | |
| if: always() | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| PR_NUMBER: ${{ github.event.pull_request.number }} | |
| run: | | |
| python3 .github/scripts/junit-report.py junit-integration.xml "Integration Test Failures" |