Skip to content

Commit

Permalink
update scripts to follow go 1.16 (#237)
Browse files Browse the repository at this point in the history
* update scripts to follow go 1.16

* update coveralls
  • Loading branch information
shrimalmadhur committed Aug 27, 2021
1 parent e1fc8df commit 392f436
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ version: 2.1
executors:
default:
docker:
- image: circleci/golang:1.15
- image: circleci/golang:1.16
user: root # go directory is owned by root
working_directory: /go/src/github.com/coinbase/rosetta-cli
environment:
Expand Down
15 changes: 11 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@
# it is necessary to use `go run <pkg>`. Running `go get` does
# not install any binaries that could be used to run
# the commands directly.
ADDLICENSE_CMD=go run github.com/google/addlicense
ADDLICENSE_INSTALL=go install github.com/google/addlicense@latest
ADDLICENSE_CMD=addlicense
ADDLICENCE_SCRIPT=${ADDLICENSE_CMD} -c "Coinbase, Inc." -l "apache" -v
GOLINES_CMD=go run github.com/segmentio/golines
GOVERALLS_CMD=go run github.com/mattn/goveralls
GOLINES_INSTALL=go install github.com/segmentio/golines@latest
GOLINES_CMD=golines
GOVERALLS_INSTALL=go install github.com/mattn/goveralls@latest
GOVERALLS_CMD=goveralls
COVERAGE_TEST_DIRECTORIES=./configuration/... ./pkg/results/... \
./pkg/logger/... ./cmd
TEST_SCRIPT=go test -v ./pkg/... ./configuration/... ./cmd
Expand Down Expand Up @@ -38,16 +41,20 @@ validate-configuration-files:
test: | validate-configuration-files
${TEST_SCRIPT}

test-cover:
test-cover:
${GOVERALLS_INSTALL}
if [ "${COVERALLS_TOKEN}" ]; then ${COVERAGE_TEST_SCRIPT} -coverprofile=c.out -covermode=count; ${GOVERALLS_CMD} -coverprofile=c.out -repotoken ${COVERALLS_TOKEN}; fi

add-license:
${ADDLICENSE_INSTALL}
${ADDLICENCE_SCRIPT} .

check-license:
${ADDLICENSE_INSTALL}
${ADDLICENCE_SCRIPT} -check .

shorten-lines:
${GOLINES_INSTALL}
${GOLINES_CMD} -w --shorten-comments pkg cmd configuration

salus:
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/coinbase/rosetta-cli

go 1.13
go 1.16

require (
github.com/coinbase/rosetta-sdk-go v0.6.8
Expand Down

0 comments on commit 392f436

Please sign in to comment.