Skip to content

Commit

Permalink
Merge pull request #55609 from software-mansion-labs/jnowakow/fix-adh…
Browse files Browse the repository at this point in the history
…oc-builds-workflow

[No QA] Pick PR number from issue description
  • Loading branch information
mountiny authored Jan 22, 2025
2 parents 55f4684 + ec9ff65 commit 92b3967
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/testBuildHybrid.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,11 @@ jobs:
const pullRequest = await github.rest.pulls.get({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: env.PULL_REQUEST_NUMBER,
pull_number: '${{ env.PULL_REQUEST_NUMBER }}'',
});
const body = pullRequest.data.body;
const regex = /MOBILE-EXPENSIFY:(?<prNumber>.*)/;
const regex = /MOBILE-EXPENSIFY:(?<prNumber>\d+)/;
const found = body.match(regex)?.groups?.prNumber || "";
return found.trim();
Expand All @@ -93,11 +93,14 @@ jobs:
outputs:
OLD_DOT_REF: ${{ steps.getHeadRef.outputs.REF }}
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Check if pull request number is correct
id: getHeadRef
run: |
set -e
echo "REF=$(gh pr view ${{ needs.getOldDotPR.outputs.OLD_DOT_PR }} --json headRefOid --jq '.headRefOid')" >> "$GITHUB_OUTPUT"
echo "REF=$(gh pr view ${{ needs.getOldDotPR.outputs.OLD_DOT_PR }} -R 'Expensify/Mobile-Expensify' --json headRefOid --jq '.headRefOid')" >> "$GITHUB_OUTPUT"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Expand Down

0 comments on commit 92b3967

Please sign in to comment.