From 369b28fbae1bd00d6c2f312ca34b27c1d0ffbf03 Mon Sep 17 00:00:00 2001 From: kei2100 Date: Sun, 5 Sep 2021 10:25:16 +0900 Subject: [PATCH 1/2] remove unnecessary mod tidy --- Makefile | 1 - 1 file changed, 1 deletion(-) diff --git a/Makefile b/Makefile index 1727778..b5f288a 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,6 @@ setup: $(GO) install golang.org/x/tools/cmd/goimports@latest $(GO) install golang.org/x/lint/golint@latest $(GO) install github.com/rakyll/gotest@latest - $(GO) mod tidy # development tasks .PHONY: fmt lint vet test test.nocache From 0e25e67a873d7aaf7e1144e7634d13e08b4c6d10 Mon Sep 17 00:00:00 2001 From: kei2100 Date: Sun, 5 Sep 2021 10:28:58 +0900 Subject: [PATCH 2/2] use orbs circleci/go@1.7.0 --- .circleci/config.yml | 46 ++++++++++++++++---------------------------- 1 file changed, 17 insertions(+), 29 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 442685e..c721955 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,14 +1,27 @@ version: 2.1 +orbs: + go: circleci/go@1.7.0 + workflows: standard: jobs: - test -executors: - standard: - docker: - - image: circleci/golang:1.16.0 +jobs: + test: + executor: + name: go/default + tag: '1.17' + steps: + - checkout + - printenv + - go/load-cache + - go/mod-download + - run: make setup + - go/save-cache + - lint + - run: make test commands: printenv: @@ -16,21 +29,6 @@ commands: - run: go version - run: go env - setup: - steps: - - restore_cache: - keys: - - go-mod-v1-{{ checksum "go.sum" }} - - go-mod-v1- - - - run: make setup - - run: go mod download - - - save_cache: - key: go-mod-v1-{{ checksum "go.sum" }} - paths: - - /go/pkg/mod/cache - lint: steps: - restore_cache: @@ -40,13 +38,3 @@ commands: key: lint-v1-{{ .Revision }} paths: - .circleci/lintok - -jobs: - test: - executor: standard - steps: - - checkout - - printenv - - setup - - lint - - run: make test