Skip to content

Commit d8e15b8

Browse files
CopilotJason3S
andauthored
ci: Prevent workflows from running unnecessarily on forks (#5127)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Jason3S <3740137+Jason3S@users.noreply.github.com>
1 parent e2600f1 commit d8e15b8

9 files changed

Lines changed: 13 additions & 0 deletions

.github/workflows/codeql-analysis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
# - https://gh.io/supported-runners-and-hardware-resources
2222
# - https://gh.io/using-larger-runners
2323
# Consider using larger runners for possible analysis time improvements.
24+
if: github.repository_owner == 'streetsidesoftware'
2425
runs-on: 'ubuntu-latest'
2526
timeout-minutes: 360
2627
permissions:

.github/workflows/deploy-website.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ permissions:
1818
jobs:
1919
build:
2020
name: Build Docusaurus
21+
if: github.repository_owner == 'streetsidesoftware'
2122
runs-on: ubuntu-latest
2223
steps:
2324
- uses: actions/checkout@v6

.github/workflows/issues-lock.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,10 @@ on:
77

88
jobs:
99
stale:
10+
if: github.repository_owner == 'streetsidesoftware'
1011
runs-on: ubuntu-latest
12+
permissions:
13+
issues: write
1114
steps:
1215
- uses: dessant/lock-threads@v6.0.0
1316
with:

.github/workflows/manual-publish.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,10 @@ on:
2525
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
2626
jobs:
2727
check_version:
28+
if: github.repository_owner == 'streetsidesoftware'
2829
runs-on: ubuntu-latest
30+
permissions:
31+
contents: read
2932
outputs:
3033
version: ${{ steps.version.outputs.version }}
3134
alpha: ${{ steps.version.outputs.alpha }}

.github/workflows/release-assets.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ permissions:
3333
jobs:
3434
build:
3535
name: Upload Assets
36+
if: github.repository_owner == 'streetsidesoftware'
3637
env:
3738
REF: ${{ inputs.ref || github.ref }}
3839
runs-on: ubuntu-latest

.github/workflows/release-mark-prerelease.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ permissions:
3333
jobs:
3434
UpdateRelease:
3535
name: Mark Release
36+
if: github.repository_owner == 'streetsidesoftware'
3637
env:
3738
REF: ${{ inputs.ref || github.ref }}
3839
runs-on: ubuntu-latest

.github/workflows/release-notes.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ permissions:
3535
jobs:
3636
build:
3737
name: Update Release Notes
38+
if: github.repository_owner == 'streetsidesoftware'
3839
env:
3940
REF: ${{ inputs.ref || github.ref }}
4041
runs-on: ubuntu-latest

.github/workflows/release-please.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ permissions:
1818

1919
jobs:
2020
release-please:
21+
if: github.repository_owner == 'streetsidesoftware'
2122
runs-on: ubuntu-latest
2223
outputs:
2324
release_created: ${{ steps.release.outputs.release_created }}

.github/workflows/set-prerelease.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ permissions:
1313
pull-requests: write
1414
jobs:
1515
set-prerelease-mode:
16+
if: github.repository_owner == 'streetsidesoftware'
1617
runs-on: ubuntu-latest
1718
steps:
1819
- uses: actions/checkout@v6

0 commit comments

Comments
 (0)