Skip to content

Commit 24953b0

Browse files
committed
[build] Fix workflows triggering with incorrect attribution on forks
1 parent 4fc4cdb commit 24953b0

4 files changed

Lines changed: 12 additions & 0 deletions

File tree

.github/workflows/build-windows.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ on:
3030

3131
jobs:
3232
build:
33+
# Skip scheduled runs in forks: GitHub attributes cron runs to the upstream
34+
# workflow author, who then gets emailed when a fork's nightly build fails.
35+
if: github.repository_owner == 'Breakthrough' || github.event_name != 'schedule'
3336
runs-on: windows-latest
3437
strategy:
3538
matrix:

.github/workflows/build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ on:
3131

3232
jobs:
3333
build:
34+
# Skip scheduled runs in forks: GitHub attributes cron runs to the upstream
35+
# workflow author, who then gets emailed when a fork's nightly build fails.
36+
if: github.repository_owner == 'Breakthrough' || github.event_name != 'schedule'
3437
runs-on: ${{ matrix.os }}
3538
strategy:
3639
fail-fast: false

.github/workflows/check-docs.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ on:
2222

2323
jobs:
2424
build:
25+
# Skip scheduled runs in forks: GitHub attributes cron runs to the upstream
26+
# workflow author, who then gets emailed when a fork's nightly build fails.
27+
if: github.repository_owner == 'Breakthrough' || github.event_name != 'schedule'
2528
runs-on: ubuntu-latest
2629

2730
steps:

.github/workflows/codeql.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ on:
2222
jobs:
2323
analyze:
2424
name: Analyze
25+
# Skip scheduled runs in forks: GitHub attributes cron runs to the upstream
26+
# workflow author, who then gets emailed when a fork's scheduled run fails.
27+
if: github.repository_owner == 'Breakthrough' || github.event_name != 'schedule'
2528
runs-on: ubuntu-latest
2629
permissions:
2730
actions: read

0 commit comments

Comments
 (0)