Skip to content

Commit

Permalink
Upgrade GitHub Actions versions
Browse files Browse the repository at this point in the history
  • Loading branch information
abicky committed Oct 28, 2024
1 parent 7e60020 commit cb6dda9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
18 changes: 6 additions & 12 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,10 @@ jobs:
- macos-latest
- windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v1
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
- uses: actions/cache@v1
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-

- run: go install go.uber.org/mock/mockgen@latest

Expand All @@ -43,19 +37,19 @@ jobs:
needs: test
if: contains(github.ref, 'tags/v')
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Check the version
run: grep -qr "version = \"$(git tag --points-at HEAD | sed 's/^v//')\"" cmd

- run: git fetch --prune --unshallow
- uses: actions/setup-go@v1
- uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
- uses: goreleaser/goreleaser-action@v1
- uses: goreleaser/goreleaser-action@v6
with:
version: latest
args: release --rm-dist
args: release --clean
env:
# Use a custom token instead of GITHUB_TOKEN for the homebrew tap
GITHUB_TOKEN: ${{ secrets.GORELEASER_GITHUB_TOKEN }}
8 changes: 5 additions & 3 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
version: 2

before:
hooks:
- go mod download
Expand All @@ -24,18 +26,18 @@ archives:
format: zip
wrap_in_directory: true
brews:
- tap:
- repository:
owner: abicky
name: homebrew-tools
homepage: "https://github.com/abicky/ecsmec"
description: "A CLI tool for Amazon ECS that provides some commands to execute bothersome operations"
folder: Formula
directory: Formula
test: |
system "#{bin}/ecsmec --version"
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ .Tag }}-next"
version_template: "{{ .Tag }}-next"
changelog:
sort: asc
filters:
Expand Down

0 comments on commit cb6dda9

Please sign in to comment.