Skip to content

Commit

Permalink
Update build testing
Browse files Browse the repository at this point in the history
* Update minimum Go version to 1.22.
* Add build test matrix.

Signed-off-by: SuperQ <[email protected]>
  • Loading branch information
SuperQ committed Oct 29, 2024
1 parent e0ad919 commit d86162c
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 12 deletions.
41 changes: 30 additions & 11 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,33 +2,52 @@
version: 2.1

orbs:
goreleaser: hubci/[email protected]

executors:
golang:
docker:
- image: cimg/go:1.20
go: circleci/[email protected]
goreleaser: hubci/[email protected]

jobs:
build:
executor: golang
parameters:
go_version:
type: string
use_gomod_cache:
type: boolean
default: true
docker:
- image: cimg/go:<< parameters.go_version >>
steps:
- checkout
- when:
condition: << parameters.use_gomod_cache >>
steps:
- go/load-cache:
key: v1-go<< parameters.go_version >>
- run: go mod download
- run: make
- when:
condition: << parameters.use_gomod_cache >>
steps:
- go/save-cache:
key: v1-go<< parameters.go_version >>

workflows:
version: 2
pro-bing:
jobs:
- build:
name: go-<< matrix.go_version >>
matrix:
parameters:
go_version:
- "1.22"
- "1.23"
filters:
tags:
only: /.*/
- goreleaser/release:
name: test-release
version: '1.16.2'
go-version: '1.20'
version: '2.3.2'
go-version: '1.23.2'
dry-run: true
requires:
- build
Expand All @@ -37,8 +56,8 @@ workflows:
only: /.*/
- goreleaser/release:
name: release
version: '1.16.2'
go-version: '1.20'
version: '2.3.2'
go-version: '1.23.2'
requires:
- build
filters:
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/prometheus-community/pro-bing

go 1.19
go 1.22

require (
github.com/google/uuid v1.6.0
Expand Down

0 comments on commit d86162c

Please sign in to comment.