Skip to content

Commit b832097

Browse files
committed
chore: expand sed match and smoke tests
1 parent 2b82081 commit b832097

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

.github/workflows/rename-module.yml

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,24 @@ jobs:
2525
- name: Globally update module name
2626
run: |
2727
go mod edit -module github.com/ava-labs/go-ethereum;
28-
find . -iname '*.go' | xargs sed -i -E \
29-
's|^((import)?\s.*?"github\.com/)ethereum/go-ethereum|\1ava-labs/go-ethereum|';
28+
find . -iname '*.go' -o -iname '*.txt' | xargs sed -i -E \
29+
's|(["`]github\.com/)ethereum/go-ethereum|\1ava-labs/go-ethereum|g';
3030
3131
- name: Set up Go
3232
uses: actions/setup-go@v5
3333
with:
3434
go-version: 1.21.4
3535

36-
- name: Smoke test by `go build ./...`
37-
run: | # `go list` just demonstrates the updated module name
38-
go list .;
39-
go build ./...
36+
- name: Smoke tests
37+
# `go list` shows us the module name
38+
# `go build` is a rudimentary but broad test of correctness
39+
# The explicitly tested packages are edge cases:
40+
# - bind creates generates tests and a go.mod on the fly
41+
# - rlpgen has testdata with imports that need updating
42+
run: |
43+
go list . | grep ava-labs;
44+
go build ./...;
45+
go test ./accounts/abi/bind ./rlp/rlpgen
4046
4147
- name: Commit to "auto-rename-module-${{ matrix.source_commit }}" branch
4248
uses: devops-infra/action-commit-push@8bc2ff9f9de7aa2a7581fc7e5b6401c04cab54c7

0 commit comments

Comments
 (0)