From ef356de66d8005301eb4a1f25e329dcedff5a1f8 Mon Sep 17 00:00:00 2001 From: Jesse van den Kieboom Date: Sat, 15 Jun 2024 11:44:47 +0200 Subject: [PATCH] Fix workflow --- .github/workflows/go.yml | 36 ++++++++++++++------------------- .travis.yml | 43 ---------------------------------------- 2 files changed, 15 insertions(+), 64 deletions(-) delete mode 100644 .travis.yml diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 1f51407..0ff3692 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -5,35 +5,29 @@ name: Go on: push: - branches: [ "master" ] + branches: ["master"] pull_request: - branches: [ "master" ] + branches: ["master"] jobs: - build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 - - - name: Set up Go - uses: actions/setup-go@v4 - with: - go-version: '1.20' + - uses: actions/checkout@v4 - - name: Build - run: go build -v ./... + - name: setup + uses: actions/setup-go@v4 + with: + go-version: "1.20" - - name: Install dependencies - run: go get -v golang.org/x/lint/golint + - name: build + run: go build -v ./... - - name: Test - run: go test -v ./... + - name: test + run: go test -v ./... - - name: Format - run: exit $(gofmt -l . | wc -l) + - name: gofmt + run: exit $(gofmt -l . | wc -l) - - name: Linting - run: | - go tool vet -all=true -v=true . || true - $(go env GOPATH | awk 'BEGIN{FS=":"} {print $1}')/bin/golint ./... + - name: vet + run: go vet -all=true -v=true . diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index ac15c41..0000000 --- a/.travis.yml +++ /dev/null @@ -1,43 +0,0 @@ -language: go - -os: - - linux - - osx - -arch: - - amd64 - - ppc64le - -go: - - 1.20.x - -install: - # go-flags - - go build -v ./... - - # linting - - go get -v golang.org/x/lint/golint - - # code coverage - - go get golang.org/x/tools/cmd/cover - - go get github.com/onsi/ginkgo/ginkgo - - go get github.com/modocache/gover - - if [ "$TRAVIS_SECURE_ENV_VARS" = "true" ]; then go get github.com/mattn/goveralls; fi - -script: - # go-flags - - $(exit $(gofmt -l . | wc -l)) - - go test -v ./... - - # linting - - go tool vet -all=true -v=true . || true - - $(go env GOPATH | awk 'BEGIN{FS=":"} {print $1}')/bin/golint ./... - - # code coverage - - $(go env GOPATH | awk 'BEGIN{FS=":"} {print $1}')/bin/ginkgo -r -cover - - $(go env GOPATH | awk 'BEGIN{FS=":"} {print $1}')/bin/gover - - if [ "$TRAVIS_SECURE_ENV_VARS" = "true" ]; then $(go env GOPATH | awk 'BEGIN{FS=":"} {print $1}')/bin/goveralls -coverprofile=gover.coverprofile -service=travis-ci -repotoken $COVERALLS_TOKEN; fi - -env: - # coveralls.io - secure: "RCYbiB4P0RjQRIoUx/vG/AjP3mmYCbzOmr86DCww1Z88yNcy3hYr3Cq8rpPtYU5v0g7wTpu4adaKIcqRE9xknYGbqj3YWZiCoBP1/n4Z+9sHW3Dsd9D/GRGeHUus0laJUGARjWoCTvoEtOgTdGQDoX7mH+pUUY0FBltNYUdOiiU="