1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-14 03:51:24 +02:00

fix(ci): go mod tidy (#2090)

Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
This commit is contained in:
Carlos Alexandro Becker 2021-03-02 21:29:31 -03:00 committed by GitHub
parent 4f7968316f
commit 5e23177a4c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 12 additions and 9 deletions

View File

@ -61,6 +61,9 @@ jobs:
name: Check name: Check
run: | run: |
./goreleaser check ./goreleaser check
-
name: Diff
run: git diff
- -
name: Docker Login name: Docker Login
if: success() && startsWith(github.ref, 'refs/tags/v') if: success() && startsWith(github.ref, 'refs/tags/v')

View File

@ -2,7 +2,7 @@ env:
- GO111MODULE=on - GO111MODULE=on
before: before:
hooks: hooks:
- go mod download - go mod tidy
- ./scripts/completions.sh - ./scripts/completions.sh
builds: builds:
- env: - env:

View File

@ -8,7 +8,7 @@ export GOPROXY = https://proxy.golang.org,direct
# Install dependencies # Install dependencies
setup: setup:
go mod download go mod tidy
.PHONY: setup .PHONY: setup
# Run all the tests # Run all the tests

View File

@ -3,7 +3,7 @@
before: before:
hooks: hooks:
# You may remove this if you don't use go modules. # You may remove this if you don't use go modules.
- go mod download - go mod tidy
# you may remove this if you don't need go generate # you may remove this if you don't need go generate
- go generate ./... - go generate ./...
builds: builds:

View File

@ -9,7 +9,7 @@ const ExampleConfig = `# This is an example .goreleaser.yml file with some sane
before: before:
hooks: hooks:
# You may remove this if you don't use go modules. # You may remove this if you don't use go modules.
- go mod download - go mod tidy
# you may remove this if you don't need go generate # you may remove this if you don't need go generate
- go generate ./... - go generate ./...
builds: builds:

View File

@ -252,13 +252,13 @@ Environment variables are inherited and overridden in the following order:
try to download the dependencies. Since several builds run in parallel, it is try to download the dependencies. Since several builds run in parallel, it is
very likely to fail. very likely to fail.
You can solve this by running `go mod download` before calling `goreleaser` or You can solve this by running `go mod tidy` before calling `goreleaser` or
by adding a [hook][] doing that on your `.goreleaser.yml` file: by adding a [hook][] doing that on your `.goreleaser.yml` file:
```yaml ```yaml
before: before:
hooks: hooks:
- go mod download - go mod tidy
# rest of the file... # rest of the file...
``` ```

View File

@ -13,11 +13,11 @@ env:
- GO111MODULE=on - GO111MODULE=on
before: before:
hooks: hooks:
- go mod download - go mod tidy
builds: builds:
- binary: program - binary: program
``` ```
This way, both `go mod download` and the underlying `go build` will have This way, both `go mod tidy` and the underlying `go build` will have
`GO111MODULE` set to `on`. `GO111MODULE` set to `on`.

View File

@ -15,7 +15,7 @@ before:
hooks: hooks:
- make clean - make clean
- go generate ./... - go generate ./...
- go mod download - go mod tidy
- touch {{ .Env.FILE_TO_TOUCH }} - touch {{ .Env.FILE_TO_TOUCH }}
``` ```