Redo rename on top of v0.30.0 #10
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: | |
| pull_request: | |
| push: | |
| branches: [master] | |
| permissions: | |
| contents: read | |
| jobs: | |
| build-and-test: | |
| name: Build and test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| submodules: 'true' | |
| - uses: actions/setup-go@v7 | |
| with: | |
| go-version-file: go.mod | |
| cache: true | |
| - name: Build | |
| run: go build ./... | |
| - name: Test | |
| run: go test -race -count=1 ./... | |
| # This repo holds several Go modules, each with its own go.mod, and | |
| # `go build ./...` never crosses a module boundary. The two steps above | |
| # therefore cover only the root module; this one covers the rest. | |
| # | |
| # The set of modules is discovered rather than written out, because it | |
| # differs on either side of an upstream sync. Right now this fork has | |
| # codelab, repl, repl/appengine and server, while current upstream has | |
| # codelab, conformance, policy, repl and tools. A hardcoded list breaks | |
| # every time that changes. | |
| # | |
| # Three are skipped because they do not build against unmodified upstream | |
| # cel-go either, so building them would report upstream's breakage as | |
| # ours: | |
| # | |
| # repl - its go.mod replaces cel.dev/expr with ../../cel-spec, a | |
| # sibling checkout that does not exist on a CI runner | |
| # codelab - stale go.mod; `go mod tidy` is needed before it builds | |
| # tools - does not compile against the version of the policy module | |
| # that it pins | |
| - name: Build other Go modules | |
| run: | | |
| skip="repl codelab tools" | |
| for m in $(git ls-files '*/go.mod' | sed 's|/go.mod$||' | sort -u); do | |
| case " $skip " in | |
| *" $m "*) echo "skipping $m"; continue ;; | |
| esac | |
| echo "::group::go build ./... ($m)" | |
| (cd "$m" && go build ./...) | |
| echo "::endgroup::" | |
| done |