Skip to content

Commit

Permalink
Release on the correct SHA
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlGao4 committed Dec 29, 2023
1 parent 18ad76d commit af7b1f5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/build-electron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ on:
paths:
- "um-react"
workflow_call:
inputs:
commit:
type: string
default: main

permissions:
contents: write
Expand Down Expand Up @@ -116,7 +120,7 @@ jobs:
upload-release:
name: Upload Release
runs-on: ubuntu-latest
if: ${{ inputs.release || github.event_name == 'push' || github.event_name == 'workflow_call' }}
if: ${{ inputs.release || github.event_name == 'push' || github.event_name == 'repository_dispatch' }}
needs: [build-linux-windows, build-macos]
steps:
- name: Download release files
Expand All @@ -131,5 +135,6 @@ jobs:
file: ${{ needs.build-linux-windows.outputs.version }}/*
tag: ${{ needs.build-linux-windows.outputs.version }}
body: Release ${{ needs.build-linux-windows.outputs.version }}
target_commit: ${{ github.event_name == 'repository_dispatch' && inputs.commit || github.sha }}
overwrite: true
file_glob: true
5 changes: 5 additions & 0 deletions .github/workflows/update-um-react.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ jobs:
update-um-react:
name: Update um-react
runs-on: ubuntu-latest
outputs:
commit: ${{ steps.push.outputs.pushed && steps.push.outputs.commit-sha || github.sha }}
steps:
- name: Checkout
uses: actions/[email protected]
Expand All @@ -23,6 +25,7 @@ jobs:
cd ..
- name: Push
id: push
uses: actions4git/add-commit-push@v1
continue-on-error: true
with:
Expand All @@ -31,3 +34,5 @@ jobs:
call-build:
uses: ./.github/workflows/build-electron.yml
needs: update-um-react
with:
commit: ${{ needs.update-um-react.outputs.commit }}

0 comments on commit af7b1f5

Please sign in to comment.