diff --git a/.github/workflows/ci-without-go-modules.yml b/.github/workflows/ci-without-go-modules.yml new file mode 100644 index 0000000..b5de85c --- /dev/null +++ b/.github/workflows/ci-without-go-modules.yml @@ -0,0 +1,44 @@ +name: Continuous Integration Without Go modules + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + name: Build + strategy: + matrix: + go: + - '1.12' + - '1.11' + - '1.10' + - '1.9' + - '1.8' + os: + - 'ubuntu-18.04' + - 'macos-10.15' + runs-on: ${{ matrix.os }} + steps: + - name: Set up Go ${{ matrix.go }} + uses: actions/setup-go@v1 + with: + go-version: ${{ matrix.go }} + + - name: Check out code into the Go module directory + uses: actions/checkout@v2 + + - name: Running static checks + run: | + export GOPATH=$HOME/go + export GOBIN=$(go env GOPATH)/bin + export PATH=$PATH:$GOPATH + export PATH=$PATH:$GOBIN + mkdir -p $GOPATH/pkg + mkdir -p $GOBIN + mkdir -p $GOPATH/src/github.com/$GITHUB_REPOSITORY + mv $(pwd)/* $GOPATH/src/github.com/$GITHUB_REPOSITORY + cd $GOPATH/src/github.com/$GITHUB_REPOSITORY + go test ./... -count=10 -race diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..fa98564 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,31 @@ +name: Continuous Integration + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + name: Build + strategy: + matrix: + go: + - '1.15' + - '1.14' + - '1.13' + os: + - 'ubuntu-18.04' + - 'macos-10.15' + runs-on: ${{ matrix.os }} + steps: + - name: Set up Go ${{ matrix.go }} + uses: actions/setup-go@v1 + with: + go-version: ${{ matrix.go }} + - name: Check out code into the Go module directory + uses: actions/checkout@v2 + + - name: Running static checks + run: make check diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 94fc20a..0000000 --- a/.travis.yml +++ /dev/null @@ -1,25 +0,0 @@ -language: go - -sudo: false - -matrix: - include: - - go: 1.8.x - - go: 1.9.x - - go: 1.10.x - - go: 1.11.x - - go: 1.12.x - - go: 1.x - env: GO111MODULE=on - - go: tip - -script: -- > - if [ "${TRAVIS_GO_VERSION}" = "1.x" ]; - then make ci; - else go test ./... -count=1 -race; - fi; -- make build - -after_success: -- bash <(curl -s https://codecov.io/bash) diff --git a/Makefile b/Makefile index 3fabb26..11636c4 100644 --- a/Makefile +++ b/Makefile @@ -105,7 +105,4 @@ checkstate: tools ## Checking the relevance of dependencies, and tools. Also, th @echo 'checking the relevance of the committed generated files' @go generate @exit $$(git status -s | wc -l) - @echo 'checking the relevance of the committed golden files' - @make testup - @exit $$(git status -s | wc -l) @go mod verify diff --git a/internal/tools/go.mod b/internal/tools/go.mod index 904e897..6069e5c 100644 --- a/internal/tools/go.mod +++ b/internal/tools/go.mod @@ -3,6 +3,7 @@ module tools go 1.12 require ( + github.com/vburenin/ifacemaker v1.1.0 // indirect golang.org/x/lint v0.0.0-20200302205851-738671d3881b golang.org/x/tools v0.0.0-20201117225735-f544f6cb68d6 ) diff --git a/internal/tools/go.sum b/internal/tools/go.sum index 26cc808..1128973 100644 --- a/internal/tools/go.sum +++ b/internal/tools/go.sum @@ -1,3 +1,10 @@ +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/jessevdk/go-flags v1.4.1-0.20181029123624-5de817a9aa20 h1:dAOsPLhnBzIyxu0VvmnKjlNcIlgMK+erD6VRHDtweMI= +github.com/jessevdk/go-flags v1.4.1-0.20181029123624-5de817a9aa20/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= +github.com/vburenin/ifacemaker v1.1.0 h1:3ScCGZ+D65Ud9L0x9ofhN0dk5QrfauzMWYfaYsfA+HE= +github.com/vburenin/ifacemaker v1.1.0/go.mod h1:SlS6qpTccQsoK3ln7mBkUxA4agA8wfPr/IFYqBWerPw= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -18,6 +25,7 @@ golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20181201035826-d0ca3933b724/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7 h1:EBZoQjiKKPaLbPrbpssUfuHtwM6KV/vb4U85g/cigFY= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=