From d75fa8941838e34c210573598b0522df7a67f63c Mon Sep 17 00:00:00 2001 From: Tej Chajed Date: Sat, 20 Jul 2024 13:07:53 -0500 Subject: [PATCH] Add CI config --- .github/workflows/build.yml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..011cc68 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,33 @@ +name: CI + +on: + push: + branches: + - main + pull_request: + +jobs: + test: + strategy: + matrix: + go-version: ["stable"] + runs-on: "ubuntu-latest" + steps: + - uses: actions/checkout@v4 + - name: Install Go + uses: actions/setup-go@v5 + with: + go-version: ${{ matrix.go-version }} + - name: Install Goose + run: | + go install github.com/goose-lang/goose/cmd/goose@latest + - name: Install dependencies + run: | + go get -t ./... + - name: Check style + run: | + gofmt -w . + git diff --exit-code + - name: Test + run: | + ./scripts/test.sh