Skip to content

Commit

Permalink
Different approach for installing linter in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
mrz1836 committed Oct 3, 2020
1 parent 8420e9b commit c0921d2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,13 @@ notifications:
email: false

# Install before running scripts
#before_script:
# - make install-lint-ci
before_script:
- curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.31.0

# Run all scripts
script:
- make test-travis
- $GOPATH/bin/golangci-lint run

# After build success
after_success:
Expand Down
6 changes: 2 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,8 @@ clean: ## Remove previous builds and any test cache data
@test $(DISTRIBUTIONS_DIR)
@if [ -d $(DISTRIBUTIONS_DIR) ]; then rm -r $(DISTRIBUTIONS_DIR); fi

lint:: ## Installs the linter and runs
@if [ "$(shell command -v golangci-lint)" = "" ]; then curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.23.8; fi
@golangci-lint
#@curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.31.0
lint:: ## Runs the golangci-lint tool
@golangci-lint run

release:: ## Runs common.release then runs godocs
@$(MAKE) godocs
Expand Down

0 comments on commit c0921d2

Please sign in to comment.