Skip to content

Commit

Permalink
ci(github-actions): use goreleaser/goreleaser-action (#261)
Browse files Browse the repository at this point in the history
  • Loading branch information
ykzts authored Jul 23, 2020
1 parent 3db453f commit 0f89aab
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ jobs:
go-version: ['1.11', '1.12', '1.13']

steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v2
- name: Set up Go ${{ matrix.go-version }}
uses: actions/setup-go@v1
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}

Expand All @@ -45,4 +45,7 @@ jobs:
token: ${{ secrets.CODECOV_TOKEN }}

- name: GoReleaser
run: curl -sL https://git.io/goreleaser | bash -s -- --snapshot
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --snapshot
13 changes: 8 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- uses: actions/setup-go@v1
- uses: actions/checkout@v2
- uses: actions/setup-go@v2
with:
go-version: 1.13
go-version: 1.14

- name: Login on Docker Hub
run: echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
run: echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin

- name: Install libwebp
run: |
Expand All @@ -39,8 +39,11 @@ jobs:
make install
- name: Release
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CGO_CFLAGS: -I/tmp/libwebp/include
CGO_LDFLAGS: -L/tmp/libwebp/lib -lwebp
run: curl -sL https://git.io/goreleaser | bash

1 comment on commit 0f89aab

@vercel
Copy link

@vercel vercel bot commented on 0f89aab Jul 23, 2020

Choose a reason for hiding this comment

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

Please sign in to comment.