-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add github action for build and lint (#6)
Signed-off-by: Pradeep Chhetri <[email protected]>
- Loading branch information
1 parent
7d3414c
commit eeed098
Showing
5 changed files
with
59 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Build, Test, Format and Lint | ||
|
||
on: | ||
push: | ||
pull_request: | ||
|
||
jobs: | ||
build-binaries: | ||
runs-on: ubuntu-latest | ||
name: Build binary | ||
steps: | ||
- uses: actions/[email protected] | ||
|
||
- uses: actions/setup-go@v2 | ||
with: | ||
go-version: ^1.19 | ||
|
||
- name: Build binaries | ||
run: make build | ||
|
||
format-lint: | ||
runs-on: ubuntu-latest | ||
name: Format and lint | ||
steps: | ||
- uses: actions/[email protected] | ||
|
||
- uses: actions/setup-go@v2 | ||
with: | ||
go-version: ^1.19 | ||
|
||
- name: Install tools | ||
run: make install-tools | ||
|
||
- name: Format | ||
run: make fmt && git diff --quiet | ||
|
||
- name: Lint | ||
run: make lint |
This file contains 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
This file contains 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
This file contains 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
This file contains 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