Skip to content

Commit

Permalink
Bump action versions in build workflow
Browse files Browse the repository at this point in the history
Also adjust the input for bluwy/substitute-string-action as per
https://github.com/orgs/community/discussions/25387#discussioncomment-3247733
  • Loading branch information
kdambekalns committed Apr 25, 2024
1 parent 13fb2f1 commit 82d7fab
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 15 deletions.
21 changes: 11 additions & 10 deletions .github/workflows/go.build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ jobs:
linux_sha256sum: ${{ steps.calculate-checksums-linux.outputs.linux_sha256sum }}
steps:

- name: Check out code into the Go module directory
uses: actions/checkout@v4

- name: Set up Go 1.22
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: '1.22'
id: go

- name: Check out code into the Go module directory
uses: actions/checkout@v4

- name: Get dependencies
run: |
go generate -v
Expand All @@ -43,13 +43,13 @@ jobs:
done
- name: Archive build result (darwin)
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: beach-osx
path: beach_darwin_amd64.zip

- name: Archive build result (linux)
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: beach-linux
path: beach_linux_amd64.zip
Expand Down Expand Up @@ -98,14 +98,15 @@ jobs:

# see: https://github.com/bluwy/substitute-string-action
- name: Substitute Homebrew variables
uses: bluwy/substitute-string-action@v2
uses: bluwy/substitute-string-action@v3
with:
_input-file: homebrew/Formula/localbeach.rb
_output-file: homebrew/Formula/localbeach.rb
_format-key: "{{key}}"
version: ${{ env.RELEASE_VERSION }}
darwin_sha256sum: ${{ needs.build.outputs.darwin_sha256sum }}
linux_sha256sum: ${{ needs.build.outputs.linux_sha256sum }}
env:
INPUT_VERSION: ${{ env.RELEASE_VERSION }}
INPUT_DARWIN_SHA256SUM: ${{ needs.build.outputs.darwin_sha256sum }}
INPUT_LINUX_SHA256SUM: ${{ needs.build.outputs.linux_sha256sum }}

- name: Commit update
run: |
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/localbeach.rb.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ class Localbeach < Formula
desc "Command-line tool for Flownative Beach"
homepage "https://www.flownative.com/beach"
license "GPL-3.0-or-later"
version "{{version}}"
version "{{VERSION}}"

if RUBY_PLATFORM.downcase.include?("darwin")
url "https://github.com/flownative/localbeach/releases/download/{{version}}/beach_darwin_amd64.zip"
sha256 "{{darwin_sha256sum}}"
url "https://github.com/flownative/localbeach/releases/download/{{VERSION}}/beach_darwin_amd64.zip"
sha256 "{{DARWIN_SHA256SUM}}"
else
url "https://github.com/flownative/localbeach/releases/download/{{version}}/beach_linux_amd64.zip"
sha256 "{{linux_sha256sum}}"
url "https://github.com/flownative/localbeach/releases/download/{{VERSION}}/beach_linux_amd64.zip"
sha256 "{{LINUX_SHA256SUM}}"
end

depends_on "mkcert" => :run
Expand Down

0 comments on commit 82d7fab

Please sign in to comment.