From d0cde3f1726de02812f1d0e22a5e8f5235b76bf6 Mon Sep 17 00:00:00 2001 From: Jakub Sobon Date: Mon, 29 Jan 2024 14:37:10 -0500 Subject: [PATCH 1/4] Defining Github action to execute Termdash CI. Signed-off-by: Jakub Sobon --- .github/go.yml | 51 ++++++++++++++++++++++++++++++++++++++++++++++++++ CHANGELOG.md | 4 ++++ 2 files changed, 55 insertions(+) create mode 100644 .github/go.yml diff --git a/.github/go.yml b/.github/go.yml new file mode 100644 index 0000000..6fc0836 --- /dev/null +++ b/.github/go.yml @@ -0,0 +1,51 @@ +# This workflow will builds and tests Termdash. +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go + +name: Go + +on: + push: + branches: [ "master", "devel" ] + pull_request: + branches: [ "master", "devel" ] + +jobs: + + build: + runs-on: ubuntu-latest + strategy: + matrix: + go-version: [ '1.20', 'stable' ] + + steps: + - uses: actions/checkout@v3 + + - name: Setup Go ${{ matrix.go-version }} + uses: actions/setup-go@v4 + with: + go-version: ${{ matrix.go-version }} + + - name: Install dependencies + run: | + go install golang.org/x/tools/cmd/cover@latest + go install github.com/mattn/goveralls@latest + go install golang.org/x/lint/golint@latest + go get -t ./... + + - name: Test + run: go test -v -covermode=count -coverprofile=coverage.out ./... + + - name: Test Race + run: CGO_ENABLED=1 go test -race ./... + + - name: Format + run: diff -u <(echo -n) <(gofmt -d -s .) + + - name: Licences + run: diff -u <(echo -n) <(./private/scripts/autogen_licences.sh .) + + - name: Lint + run: diff -u <(echo -n) <(golint ./...) + + - name: Coverage + run: $GOPATH/bin/goveralls -coverprofile=coverage.out -service=travis-ci -repotoken $COVERALLS_TOKEN diff --git a/CHANGELOG.md b/CHANGELOG.md index d13f911..b2e8098 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changed + +- Migrated CI system from Travis to Github Actions. + ## [0.18.0] - 08-Feb-2023 ### Added From 343f50342e28051be0ccfe43499a361ab0001f29 Mon Sep 17 00:00:00 2001 From: Jakub Sobon Date: Mon, 29 Jan 2024 14:39:40 -0500 Subject: [PATCH 2/4] Undo CHANGELOG change. Signed-off-by: Jakub Sobon --- CHANGELOG.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b2e8098..0f7d8fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,8 +9,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed -- Migrated CI system from Travis to Github Actions. - ## [0.18.0] - 08-Feb-2023 ### Added From 83c2b44eaa87214c8d739ee8300da4abaca63f61 Mon Sep 17 00:00:00 2001 From: Jakub Sobon Date: Mon, 29 Jan 2024 14:42:17 -0500 Subject: [PATCH 3/4] Remove the Travis workflow. Signed-off-by: Jakub Sobon --- .travis.yml | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 96ec6a9..0000000 --- a/.travis.yml +++ /dev/null @@ -1,21 +0,0 @@ -language: go -go: - - 1.20.x - - stable -before_install: - - go install golang.org/x/tools/cmd/cover@latest - - go install github.com/mattn/goveralls@latest - - go install golang.org/x/lint/golint@latest -script: - - go get -t ./... - - go test -v -covermode=count -coverprofile=coverage.out ./... - - CGO_ENABLED=1 go test -race ./... - - go vet ./... - - diff -u <(echo -n) <(gofmt -d -s .) - - diff -u <(echo -n) <(./private/scripts/autogen_licences.sh .) - - diff -u <(echo -n) <(golint ./...) - - $GOPATH/bin/goveralls -coverprofile=coverage.out -service=travis-ci -repotoken $COVERALLS_TOKEN -env: - global: - - CGO_ENABLED=0 - - secure: FEFt9o7MvSvK2lnXJTydml/DCmNqPKIc+YJjPlKhfeGGJyruFvP55qkB0rHN7wb2r4L44qMqtM12c41YzA0sFhXXNowhCB0wd7mfyEt3cCLr4akqRedxOpz+qFBGv2oCBObP6e6irtsN0071KtDz9wsITchme3gf0A8l9PhjPeEu9UVbmN8lipouvQFqmdxqLNyxJ+ykbACkSTwIx2rkvU79aOPDoSnDO56Wqaq7V75CmZ13EtHupgmJIz2GECyIL6Ll6824AQiK1O5XXpnc8973Vw1s6kZB5Tyzvb2KaW5U9KhovgX1mTvnj1XJ//SQvh9yMjC5L51DLNbLSshVo7L4CiJZkq8QQLFILPOMaC1emrmhXxwizjbTmNOo96t2MYk2WASq636Uoez0ZkkZPjuwuKoexFi7r04vHEOjnF2N9liN+M8gwvJ5N/MakbS3ZPbZ+57w4xgwuxJRSUYQoT1VSU8E2rc+DQYa4HzY4wrcrJQG7HBjd4KBHnmHjEDAmawBb6iEI9d5d40j0LThxAOweh05YoWVmnTzMScuO27V5embStXab31jUrD4Qnj5/lliklGdYD5aWLKRZhSeg5mLikUITbhriABuUxMaR1FuQW4r1nSg3n8XA6MbwdvngO2DJyzp5iUQX3yfnUgrGzfp9okrA4CdxUHrY/jj8cw= From 45a2042afb04571b1c7e492d12b2204e54ada4d9 Mon Sep 17 00:00:00 2001 From: Jakub Sobon Date: Mon, 29 Jan 2024 14:42:58 -0500 Subject: [PATCH 4/4] Undo changes in CHANGELOG. Signed-off-by: Jakub Sobon --- CHANGELOG.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0f7d8fe..d13f911 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,8 +7,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] -### Changed - ## [0.18.0] - 08-Feb-2023 ### Added