Skip to content

Commit

Permalink
Update config.yml (#40)
Browse files Browse the repository at this point in the history
* Update config.yml

* fix go version

* fix go version

* removing working directory stanza
  • Loading branch information
issmirnov authored Mar 6, 2024
1 parent 3cba322 commit ebce54e
Showing 1 changed file with 18 additions and 5 deletions.
23 changes: 18 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
# Golang CircleCI 2.0 configuration file
#
# Check https://circleci.com/docs/2.0/language-go/ for more details
docker-image: &docker-image circleci/golang:1.15
docker-image: &docker-image cimg/go:1.20
version: 2
jobs:
lint:
docker:
- image: *docker-image
working_directory: /go/src/github.com/issmirnov/zap
steps:
- checkout
- run: diff -u <(echo -n) <(go fmt $(go list ./...))
Expand All @@ -17,19 +16,33 @@ jobs:
build_and_test:
docker:
# specify the version
- image: circleci/golang:1.15
- image: *docker-image

working_directory: /go/src/github.com/issmirnov/zap
steps:
- checkout
- run: go build -o zap -v ./cmd/
- run: go test -short -v ./... -race -coverprofile=coverage.txt -covermode=atomic ./cmd
- run: go test -v ./...
- run: ./e2e.sh
release:
docker:
- image: *docker-image
steps:
- checkout
- run: curl -sfL https://goreleaser.com/static/run | bash

workflows:
version: 2
build_and_test:
jobs:
- lint
- build_and_test
- build_and_test
main:
jobs:
- release:
# Only run this job on git tag pushes
filters:
branches:
ignore: /.*/
tags:
only: /v[0-9]+(\.[0-9]+)*(-.*)*/

0 comments on commit ebce54e

Please sign in to comment.