Skip to content

Commit

Permalink
build(ci): add go mod tidy check
Browse files Browse the repository at this point in the history
  • Loading branch information
frrist committed Nov 25, 2020
1 parent 51160b5 commit f4a5aa5
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,45 @@
version: 2.1
orbs:
go: gotest/[email protected]

executors:
dockerizer:
docker:
- image: cimg/go:1.15.2
environment:
IMAGE_NAME: filecoin/sentinel-visor
golang:
docker:
- image: circleci/golang:1.13

commands:
install-deps:
steps:
- go/install-ssh
- go/install: {package: git}
prepare:
parameters:
linux:
default: true
description: is a linux build environment?
type: boolean
steps:
- checkout
- when:
condition: << parameters.linux >>
steps:
- run: sudo apt-get update
- run: git submodule sync
- run: git submodule update --init

jobs:
mod-tidy-check:
executor: golang
steps:
- install-deps
- prepare
- go/mod-tidy-check

test:
docker:
- image: cimg/go:1.15.2
Expand Down Expand Up @@ -74,6 +106,7 @@ workflows:
# `docker-push` runs master or main branches and tags that look like semver
# see: https://circleci.com/docs/2.0/workflows/#executing-workflows-for-a-git-tag
jobs:
- mod-tidy-check
- test
- docker-build:
filters:
Expand Down

0 comments on commit f4a5aa5

Please sign in to comment.