Skip to content

Commit

Permalink
chore: add ci
Browse files Browse the repository at this point in the history
  • Loading branch information
takaishi committed Aug 29, 2024
1 parent 2242cb7 commit 987940d
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 2 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: test

on:
pull_request:
branches: [ main ]

jobs:
test:
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v2
with:
go-version: 1.21
- uses: actions/checkout@v3
with:
fetch-depth: 0
- run: make build
- run: make test
9 changes: 7 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@

build:
.PHONY: build
build: test
go build -o dist/tfclean ./cmd/tfclean

.PHONY: install
install:
go install github.com/takaishi/tfclean/cmd/tfclean

.PHONY: test
test:
go test -race ./...

0 comments on commit 987940d

Please sign in to comment.