Skip to content

Commit d75ea66

Browse files
committed
Add GitHub Actions CI workflow
- Created a new GitHub Actions workflow for CI. - The workflow runs on every push to the main branch. - It sets up Go, checks out the code, gets dependencies, builds the project, and runs tests. Signed-off-by: Daniel Hu <[email protected]>
1 parent 758b86d commit d75ea66

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

.github/workflows/ci.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
build-and-test:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Set up Go
14+
uses: actions/setup-go@v2
15+
with:
16+
go-version: 1.20
17+
18+
- name: Check out code into the Go module directory
19+
uses: actions/checkout@v2
20+
21+
- name: Get dependencies
22+
run: go get -v -t -d ./...
23+
24+
- name: Build
25+
run: go build -v ./...
26+
27+
- name: Test
28+
run: go test -v ./...

0 commit comments

Comments
 (0)