Skip to content

Commit

Permalink
Fix workflow_dispatch for ci.yml (#1295)
Browse files Browse the repository at this point in the history
* [bfops/fix-workflow-dispatch]: fix

* [bfops/fix-workflow-dispatch]: empty

* [bfops/fix-workflow-dispatch]: fix?

* [bfops/fix-workflow-dispatch]: fix?

---------

Co-authored-by: Zeke Foppa <github.com/bfops>
  • Loading branch information
bfops authored May 24, 2024
1 parent 7cf48e8 commit dda15b7
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,12 @@ jobs:
runs-on: spacetimedb-runner
steps:
- name: Find Git ref
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_NUMBER="${{ github.event.inputs.pr_number || null }}"
if test -n "${PR_NUMBER}"; then
GIT_REF="$( gh pr view $PR_NUMBER --json headRefName --jq .headRefName )"
GIT_REF="$( gh pr view --repo clockworklabs/SpacetimeDB $PR_NUMBER --json headRefName --jq .headRefName )"
else
GIT_REF="${{ github.ref }}"
fi
Expand All @@ -49,10 +51,12 @@ jobs:
runs-on: spacetimedb-runner
steps:
- name: Find Git ref
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_NUMBER="${{ github.event.inputs.pr_number || null }}"
if test -n "${PR_NUMBER}"; then
GIT_REF="$( gh pr view $PR_NUMBER --json headRefName --jq .headRefName )"
GIT_REF="$( gh pr view --repo clockworklabs/SpacetimeDB $PR_NUMBER --json headRefName --jq .headRefName )"
else
GIT_REF="${{ github.ref }}"
fi
Expand Down

0 comments on commit dda15b7

Please sign in to comment.