Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Skip running jobs on fork develop where they lack secrets (#8837)
Browse files Browse the repository at this point in the history
* Skip running jobs on fork `develop` where they lack secrets

* Fix contexts
  • Loading branch information
t3chguy committed Jun 14, 2022
1 parent 2c751a4 commit 79195de
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/cypress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,12 +122,13 @@ jobs:
runs-on: ubuntu-latest
if: |
github.event.workflow_run.event != 'pull_request' &&
github.event.workflow_run.head_branch == 'develop'
github.event.workflow_run.head_branch == 'develop' &&
github.event.workflow_run.head_repository.full_name == github.repository
permissions:
contents: write
steps:
- uses: actions/checkout@v2

- name: Download benchmark result
uses: actions/download-artifact@v3
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/end-to-end-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
# won't pull in the right versions of other repos, so they're only enabled
# on develop.
push:
branches: [ develop ]
branches: [ develop, master ]
pull_request:
branches: [ develop ]
repository_dispatch:
Expand Down Expand Up @@ -41,7 +41,7 @@ jobs:
retention-days: 14
- name: Store benchmark result
if: github.ref == 'refs/heads/develop'
if: github.ref == 'refs/heads/develop' && github.repository == 'matrix-org/matrix-react-sdk'
uses: matrix-org/github-action-benchmark@jsperfentry-1
with:
tool: 'jsperformanceentry'
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/notify-element-web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ jobs:
notify-element-web:
name: "Notify Element Web"
runs-on: ubuntu-latest
# Only respect triggers from our develop branch, ignore that of forks
if: github.repository == 'matrix-org/matrix-react-sdk'
steps:
- name: Notify element-web repo that a new SDK build is on develop
uses: peter-evans/repository-dispatch@v1
Expand Down

0 comments on commit 79195de

Please sign in to comment.