Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: update bitrise e2e check to not run on forks #10128

Merged
merged 2 commits into from
Jun 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 16 additions & 1 deletion .github/workflows/run-bitrise-e2e-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,24 @@ env:
WORKFLOW_NAME: 'run-bitrise-e2e-check'

jobs:
is-fork-pull-request:
name: Determine pull request source
if: ${{ github.event.issue.pull_request || github.event_name == 'pull_request' }}
runs-on: ubuntu-latest
outputs:
IS_FORK: ${{ steps.is-fork.outputs.IS_FORK }}
steps:
- uses: actions/checkout@v3
- name: Determine whether this PR is from a fork
id: is-fork
run: echo "IS_FORK=$(gh pr view --json isCrossRepository --jq '.isCrossRepository' "${{ github.event.number }}" )" >> "$GITHUB_OUTPUT"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

run-bitrise-e2e-check:
needs: is-fork-pull-request
runs-on: ubuntu-latest
if: ${{ github.event.issue.pull_request || github.event_name == 'pull_request' }}
if: ${{ needs.is-fork-pull-request.outputs.IS_FORK == 'false' }}
permissions:
pull-requests: write
contents: write
Expand Down
Loading