Skip to content

Commit

Permalink
Add matrix build for multiple Go versions (#68)
Browse files Browse the repository at this point in the history
  • Loading branch information
Krzysztof Reczek authored Jul 12, 2022
1 parent a28653b commit 2d7ae91
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 7 deletions.
23 changes: 17 additions & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,20 @@ version: 2.1
orbs:
slack: circleci/slack@4.9.4

defaults: &defaults
docker:
- image: cimg/go:1.18
executors:
go117:
docker:
- image: cimg/go:1.17
go118:
docker:
- image: cimg/go:1.18

jobs:
build:
<<: *defaults
parameters:
docker-image:
type: executor
executor: << parameters.docker-image >>
steps:
- checkout
- restore_cache:
Expand Down Expand Up @@ -37,7 +44,8 @@ jobs:
template: basic_success_1

release:
<<: *defaults
docker:
- image: cimg/go:1.18
steps:
- checkout
- run:
Expand All @@ -61,7 +69,10 @@ workflows:
version: 2
build-release:
jobs:
- build
- build:
matrix:
parameters:
docker-image: [ go117, go118 ]
- release:
requires:
- build
Expand Down
2 changes: 1 addition & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: '3'
tasks:
test:
cmds:
- go test -v ./...
- go test -race -v ./...

test_examples:
cmds:
Expand Down

0 comments on commit 2d7ae91

Please sign in to comment.