passforios-gopenpgp/.github/workflows/go.yml
wussler 6b2ac0b11c
Migrate CI to actions, build artifacts (#89)
* Create go workflow

* Delete travis config

* Update build script

* Create apple workflow

* Create android workflow

Co-authored-by: marin thiercelin <marin.thiercelin@pm.me>
2020-10-19 10:07:25 +02:00

38 lines
773 B
YAML

name: Go test and lint
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v2
- name: Get dependencies
run: |
go get -v -t -d ./...
if [ -f Gopkg.toml ]; then
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure
fi
go install github.com/golangci/golangci-lint/cmd/golangci-lint
- name: Test
run: go test -v -race ./...
- name: Lint
run: golangci-lint run ./...