mirror of
https://github.com/go-sylixos/elvish.git
synced 2024-11-27 15:01:22 +08:00
Make tools/check-gen.sh fail if go generate fails.
Also configure the CI workflow to install stringer.
This commit is contained in:
parent
a537d12f40
commit
4a24084b38
16
.github/workflows/ci.yml
vendored
16
.github/workflows/ci.yml
vendored
|
@ -110,12 +110,16 @@ jobs:
|
|||
uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: 1.19.x
|
||||
- name: Install goimports
|
||||
run: go install golang.org/x/tools/cmd/goimports@latest
|
||||
- name: Install codespell
|
||||
run: pip install codespell==2.2.1
|
||||
- name: Install staticcheck
|
||||
run: go install honnef.co/go/tools/cmd/staticcheck@v0.3.2
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.x'
|
||||
- name: Install tools
|
||||
run: |
|
||||
go install golang.org/x/tools/cmd/stringer@latest
|
||||
go install golang.org/x/tools/cmd/goimports@latest
|
||||
go install honnef.co/go/tools/cmd/staticcheck@v0.3.2
|
||||
pip install --user codespell==2.2.1
|
||||
- name: Run checks
|
||||
run: make all-checks
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ if test "$(git_unstaged)" != ""; then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
go generate ./...
|
||||
go generate ./... || exit 1
|
||||
x=$(git_unstaged)
|
||||
|
||||
if test "$x" != ""; then
|
||||
|
|
Loading…
Reference in New Issue
Block a user