Skip to content

Commit

Permalink
add basic CI
Browse files Browse the repository at this point in the history
  • Loading branch information
chlowell committed Apr 27, 2023
1 parent 0b9308d commit 8939ff6
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Build and Test

on:
pull_request:
types: [opened, reopened, synchronize]
push:
branches: [dev, main]

jobs:
build_test:
strategy:
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]

runs-on: ${{matrix.os}}

steps:
- uses: actions/checkout@v3

- uses: actions/setup-go@v4
with:
go-version-file: "go.mod"

- name: Build
run: go build -x ./extensions/...

- name: Test
run: go test -race -v ./...

- name: Lint
# lint even when a previous step failed
if: ${{!cancelled()}}
uses: golangci/golangci-lint-action@v3
with:
version: v1.52
args: -v
9 changes: 9 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
linters:
enable:
- gocritic
- gofmt

linters-settings:
gocritic:
enabled-checks:
- evalOrder

0 comments on commit 8939ff6

Please sign in to comment.