From 39b4ebfdb2f72fac26bab97ba259b6eb7e7254e1 Mon Sep 17 00:00:00 2001 From: Terry McGuinness Date: Fri, 1 Nov 2024 10:40:07 -0500 Subject: [PATCH 1/2] left out updates from OCB PR for PRs from forked repos --- .github/workflows/pw_aws_ci.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/pw_aws_ci.yaml b/.github/workflows/pw_aws_ci.yaml index 245e219dd4..33011322b5 100644 --- a/.github/workflows/pw_aws_ci.yaml +++ b/.github/workflows/pw_aws_ci.yaml @@ -45,10 +45,13 @@ jobs: repo=${{ github.repository }} if [ "$pr_number" -eq "0" ]; then branch=${{ github.event.inputs.ref }} + repo_url="https://github.com/${{ github.repository_owner }}/${{ github.repository }}.git" else branch=$(gh pr view $pr_number --repo $repo --json headRefName --jq '.headRefName') + repo_url=$(gh pr view $pr_number --repo $repo --json headRepository --jq '.headRepository.url') fi echo "::set-output name=branch::$branch" + echo "::set-output name=repo::$repo_url" checkout: needs: fetch-branch @@ -64,6 +67,7 @@ jobs: with: path: ${{ github.run_id }}/HOMEgfs submodules: 'recursive' + repository: ${{ needs.fetch-branch.outputs.repo }} ref: ${{ needs.fetch-branch.outputs.branch }} build-link: From 8e4a93fac97eab5cb34f5ab2e992d88f842d1ea8 Mon Sep 17 00:00:00 2001 From: Terry McGuinness Date: Fri, 1 Nov 2024 11:22:56 -0500 Subject: [PATCH 2/2] updated bug for pass repo output arguments to checkout in CI GitHub pipeline for pw --- .github/workflows/pw_aws_ci.yaml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pw_aws_ci.yaml b/.github/workflows/pw_aws_ci.yaml index c59f027920..f97825c5bc 100644 --- a/.github/workflows/pw_aws_ci.yaml +++ b/.github/workflows/pw_aws_ci.yaml @@ -80,8 +80,10 @@ jobs: branch=$(gh pr view $pr_number --repo $repo --json headRefName --jq '.headRefName') repo_url=$(gh pr view $pr_number --repo $repo --json headRepository --jq '.headRepository.url') fi - echo "::set-output name=branch::$branch" - echo "::set-output name=repo::$repo_url" + { + echo "BRANCH=$branch" + echo "REPO=$repo_url" + } >> $GITHUB_OUTPUT checkout: needs: fetch-branch @@ -97,8 +99,8 @@ jobs: with: path: ${{ github.run_id }}/HOMEgfs submodules: 'recursive' - repository: ${{ needs.fetch-branch.outputs.repo }} - ref: ${{ needs.fetch-branch.outputs.branch }} + repository: ${{ steps.git-branch.outputs.BRANCH }} + ref: ${{ steps.git-branch.outputs.REPO }} build-link: needs: checkout