-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
.github: update GitHub Workflows (#70)
Updated ci.yml, ci-go-cover.yml, govulncheck.yml, and safer-golangci-lint.yml. Update ci.yml: - Add concurrency group. - Run on all tags on push. - Test go1.17 + latest 2 versions (go1.22 and go1.23). Update ci-go-cover.yml - Copy latest ci-go-cover.yml from https://github.com/fxamacker/cbor - Bump go to go1.23. - Add concurrency group. - Pin dependencies. Update govulncheck.yml - Run on all pull requests for all branches. - Run on all push for all branches. - Run daily at 12:45 UTC / 7:45 AM Central. - Add concurrency group. - Bump go to go1.23. Update safer-golangci-lint.yml - Copy latest yml from https://github.com/fxamacker/cbor - Bump golangci-lint to 1.59.1. - Bump go to go1.22. - Add concurrency group.
- Loading branch information
Showing
4 changed files
with
51 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# Copyright 2020-present Montgomery Edwards⁴⁴⁸ (github.com/x448). | ||
# Copyright 2020-2023 Montgomery Edwards⁴⁴⁸ (github.com/x448). | ||
# This file is licensed under the MIT License. See LICENSE at https://github.com/x448/workflows for the full text. | ||
# | ||
# CI Go Cover 2020.1.28. | ||
# CI Go Cover 2023.5.14. | ||
# This GitHub Actions workflow checks if Go (Golang) code coverage satisfies the required minimum. | ||
# The required minimum is specified in the workflow name to keep badge.svg and verified minimum in sync. | ||
# | ||
|
@@ -19,36 +19,37 @@ name: cover 100% | |
# Remove default permissions. | ||
permissions: {} | ||
|
||
on: [push] | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
push: | ||
branches: [main] | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.run_id }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
|
||
# Verify minimum coverage is reached using `go test -short -cover` on latest-ubuntu with default version of Go. | ||
# The grep expression can't be too strict, it needed to be relaxed to work with different versions of Go. | ||
cover: | ||
name: Coverage on ${{matrix.os}} | ||
name: Coverage | ||
permissions: | ||
contents: read | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
# Only need one OS | ||
# Need at least one Go <= 1.16 until *_oldgo.go is removed or changes its build tag | ||
# Need at least one Go >= 1.17 until build tags require newer version or are removed | ||
os: [ubuntu-latest] | ||
go-version: [1.16.x, 1.17.x] | ||
|
||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0 | ||
- name: Install Go | ||
uses: actions/[email protected] | ||
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2 | ||
with: | ||
go-version: ${{ matrix.go-version }} | ||
# Support for go1.16 (*_oldgo.go) is deprecated as of Sunday,l Oct 6, 2024 so it won't be checked. | ||
# Coverage test will fail if it drops below 100% and we only need one version of Go here. | ||
go-version: 1.23 | ||
check-latest: true | ||
|
||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 1 | ||
|
||
- name: Install x448/float16 | ||
run: go get github.com/x448/[email protected] | ||
- name: Go Coverage | ||
run: | | ||
go version | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters