Skip to content

Commit

Permalink
Merge pull request #530 from per1234/fix-release-workflow
Browse files Browse the repository at this point in the history
Fix collision between macOS workflow artifacts in release workflows
  • Loading branch information
per1234 authored Nov 6, 2024
2 parents 4e7a852 + 973700b commit 06e6a0e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
11 changes: 7 additions & 4 deletions workflow-templates/publish-go-nightly-task.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,11 @@ jobs:
strategy:
matrix:
build:
- folder-suffix: darwin_amd64
- artifact-suffix: macOS_64bit
folder-suffix: darwin_amd64
package-suffix: "macOS_64bit.tar.gz"
- folder-suffix: darwin_arm64
- artifact-suffix: macOS_ARM64
folder-suffix: darwin_arm64
package-suffix: "macOS_ARM64.tar.gz"

steps:
Expand Down Expand Up @@ -173,11 +175,12 @@ jobs:
-C ../../ LICENSE.txt
echo "PACKAGE_FILENAME=$PACKAGE_FILENAME" >> $GITHUB_ENV
- name: Upload artifact
- name: Replace artifact with notarized build
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: ${{ env.ARTIFACT_PREFIX }}notarized-${{ matrix.build.folder-suffix }}
name: ${{ env.ARTIFACT_PREFIX }}${{ matrix.build.artifact-suffix }}
overwrite: true
path: ${{ env.DIST_DIR }}/${{ env.PACKAGE_FILENAME }}

publish-nightly:
Expand Down
11 changes: 7 additions & 4 deletions workflow-templates/release-go-task.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,11 @@ jobs:
strategy:
matrix:
build:
- folder-suffix: darwin_amd64
- artifact-suffix: macOS_64bit
folder-suffix: darwin_amd64
package-suffix: "macOS_64bit.tar.gz"
- folder-suffix: darwin_arm64
- artifact-suffix: macOS_ARM64
folder-suffix: darwin_arm64
package-suffix: "macOS_ARM64.tar.gz"

steps:
Expand Down Expand Up @@ -179,11 +181,12 @@ jobs:
-C "${{ env.BUILD_FOLDER }}/" "${{ env.PROJECT_NAME }}" \
-C ../../ LICENSE.txt
- name: Upload artifact
- name: Replace artifact with notarized build
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: ${{ env.ARTIFACT_PREFIX }}notarized-${{ matrix.build.folder-suffix }}
name: ${{ env.ARTIFACT_PREFIX }}${{ matrix.build.artifact-suffix }}
overwrite: true
path: ${{ env.DIST_DIR }}/${{ env.PACKAGE_FILENAME }}

create-release:
Expand Down

0 comments on commit 06e6a0e

Please sign in to comment.