Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: cli

on:
push:
branches: [ master ]
pull_request:
workflow_dispatch:

jobs:
ci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: stable

- run: go mod tidy
- run: go build -v ./...

- run: go install golang.org/x/tools/cmd/goimports@latest
- run: go install mvdan.cc/gofumpt@latest
- run: go install honnef.co/go/tools/cmd/staticcheck@latest

- run: goimports -w . && gofumpt -w .

- name: Verify no changes
run: |
if [ -n "$(git diff)" ]; then
git diff
exit 1
fi

- run: go test -v ./...

- run: go vet -v ./...
- run: staticcheck ./...