Skip to content

Commit

Permalink
Migrate CI to Github Actions. (#225)
Browse files Browse the repository at this point in the history
* Migrate CI to Github Actions

Co-authored-by: louyuting <[email protected]>
  • Loading branch information
sdttttt and louyuting authored Sep 5, 2020
1 parent 8b17e24 commit 3263459
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 20 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: CI

on:
pull_request:
branches: "*"

jobs:

build:
name: ubuntu-latest ${{ matrix.config.go_version }}
runs-on: ubuntu-latest
strategy:
matrix:
config:
- go_version: 1.13
- go_version: 1.14
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.config.go_version }}
id: go

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Install goimports
run: go get golang.org/x/tools/cmd/goimports

- name: Test
run: |
diff -u <(echo -n) <(gofmt -d -s .)
diff -u <(echo -n) <(goimports -d .)
go test -v -race ./... -coverprofile=coverage.txt -covermode=atomic
- name: Coverage
run: bash <(curl -s https://codecov.io/bash)
20 changes: 0 additions & 20 deletions .travis.yml

This file was deleted.

0 comments on commit 3263459

Please sign in to comment.