Skip to content

update dependency and add demo for consul2istio #9

update dependency and add demo for consul2istio

update dependency and add demo for consul2istio #9

Workflow file for this run

---
name: ci
on: [push, pull_request]
jobs:
build-and-test:
name: build and test
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v2
- name: Setup Go
uses: actions/setup-go@v1
with:
go-version: 1.14.4
- name: Build
run: go build -race ./...
- name: Test
run: go test -race ./...
golangci-lint:
name: golangci-lint
runs-on: ubuntu-latest
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v2
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
- uses: actions/checkout@v2
with:
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
version: v1.31
style-check:
name: gofmt and goimports
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v2
- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: 1.14.4
- name: Install dependencies
run: |
go version
go get golang.org/x/tools/cmd/goimports
- name: gofmt and goimports
run: |
gofmt -l -d ./
goimports -l -d ./
checkgomod:
name: check go.mod and go.sum
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v1
with:
go-version: 1.14.4
- run: go mod tidy
- name: Check for changes in go.mod or go.sum
run: |
git diff --name-only --exit-code go.mod || ( echo "Run go tidy" && false )
git diff --name-only --exit-code go.sum || ( echo "Run go tidy" && false )