Skip to content

Explicitly pass GITHUB_TOKEN env to goreleaser action #1215

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 8, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .github/workflows/tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,17 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Install Go
uses: actions/setup-go@v1
uses: actions/setup-go@v2
with:
go-version: 1.14
- name: Unshallow
run: git fetch --prune --unshallow
- name: Login do docker.io
run: docker login -u golangci -p ${{ secrets.GOLANGCI_LINT_DOCKER_TOKEN }}
- name: Create release
uses: goreleaser/goreleaser-action@v1
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist
env:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

Just curious on how to re-run, or one more release is required.

Copy link
Member Author

@SVilgelm SVilgelm Jul 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually it's impossible to re run this action because it triggers on a tag event:

on:
  push:
    tags:
      - v*

You can re-run failed actions, but they will use an old code.
Only one way to avoid a new release is run goreleaser manually

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems like only brew release was failing, I think we can re-run manually for brew only. /cc @golangci/team @golangci/core-team

GITHUB_TOKEN: ${{ secrets.GOLANGCI_LINT_TOKEN }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nits we can refer to env define in job level as well, something like ${{ env.GITHUB_TOKEN }}, but I think it's fine to use secrets.GOLANGCI_LINT_TOKEN here :)

4 changes: 2 additions & 2 deletions assets/github-action-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@
"AssetURL": "https://github.com/golangci/golangci-lint/releases/download/v1.27.0/golangci-lint-1.27.0-linux-amd64.tar.gz"
},
"v1.28": {
"TargetVersion": "v1.28.0",
"AssetURL": "https://github.com/golangci/golangci-lint/releases/download/v1.28.0/golangci-lint-1.28.0-linux-amd64.tar.gz"
"TargetVersion": "v1.28.1",
"AssetURL": "https://github.com/golangci/golangci-lint/releases/download/v1.28.1/golangci-lint-1.28.1-linux-amd64.tar.gz"
},
"v1.3": {
"Error": "golangci-lint version 'v1.3' isn't supported: we support only v1.14.0 and later versions"
Expand Down