mirror of
https://github.com/vbatts/git-validation.git
synced 2024-11-22 16:15:40 +00:00
add github actions
For now, we'll leave travis, since we have logic for it. Once Travis stops working, then we'll remove the logic and the ./.travis.yml Fixes #50 Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
parent
60cb871391
commit
25069be637
1 changed files with 37 additions and 0 deletions
37
.github/workflows/go.yml
vendored
Normal file
37
.github/workflows/go.yml
vendored
Normal file
|
@ -0,0 +1,37 @@
|
|||
name: vet and build
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches_ignore: []
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
go: ['1.13', '1.14', '1.15', '1.16']
|
||||
|
||||
name: Documentation and Linting
|
||||
steps:
|
||||
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
path: go/src/github.com/vbatts/git-validation
|
||||
|
||||
# commit for v1 release
|
||||
- uses: actions/setup-go@0caeaed6fd66a828038c2da3c0f662a42862658f
|
||||
with:
|
||||
go-version: ${{ matrix.go }}
|
||||
|
||||
- name: vet and build
|
||||
env:
|
||||
GOPATH: /home/runner/work/git-validation/git-validation/go
|
||||
run: |
|
||||
set -x
|
||||
export PATH=$GOPATH/bin:$PATH
|
||||
cd go/src/github.com/vbatts/git-validation
|
||||
go get ./...
|
||||
go vet -x ./...
|
||||
go build -v .
|
||||
go test -v ./...
|
||||
./git-validation -run DCO,short-subject,dangling-whitespace -v -range ${GITHUB_SHA}..HEAD
|
Loading…
Reference in a new issue