From b5f727dc60d9ae778ce0882ac80291389c91a905 Mon Sep 17 00:00:00 2001 From: Ryan Hendrickson <8751750+rynhndrcksn@users.noreply.github.com> Date: Sun, 1 Sep 2024 11:08:30 -0700 Subject: [PATCH] ci: add github-action.yml --- .github/workflows/github-action.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/github-action.yml diff --git a/.github/workflows/github-action.yml b/.github/workflows/github-action.yml new file mode 100644 index 0000000..64ca739 --- /dev/null +++ b/.github/workflows/github-action.yml @@ -0,0 +1,28 @@ +name: "CI" + +on: [ "pull-request" ] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + go: [ '1.22.x', '1.23.x' ] + + steps: + - uses: actions/checkout@v4 + - name: "Set up Go..." + uses: WillAbides/setup-go-faster@v1 + with: + go-version: ${{ matrix.go }} + - name: "Install dependencies..." + run: go get . + - name: "Vetting code..." + run: go vet ./... + - uses: dominikh/staticcheck-action@v1 + with: + version: "latest" + install-go: false + cache-key: ${{ matrix.go }} + - name: "Running tests..." + run: go test -race -vet=off ./...