Skip to content

Backport PR #30118 on branch v3.10.3-doc (CI: Skip jobs on forks) #30141

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

Merged
Show file tree
Hide file tree
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
38 changes: 21 additions & 17 deletions .github/workflows/cibuildwheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,16 @@ permissions:
jobs:
build_sdist:
if: >-
github.event_name == 'push' ||
github.event_name == 'pull_request' && (
(
github.event.action == 'labeled' &&
github.event.label.name == 'CI: Run cibuildwheel'
) ||
contains(github.event.pull_request.labels.*.name,
'CI: Run cibuildwheel')
github.repository == 'matplotlib/matplotlib' && (
github.event_name == 'push' ||
github.event_name == 'pull_request' && (
(
github.event.action == 'labeled' &&
github.event.label.name == 'CI: Run cibuildwheel'
) ||
contains(github.event.pull_request.labels.*.name,
'CI: Run cibuildwheel')
)
)
name: Build sdist
runs-on: ubuntu-latest
Expand Down Expand Up @@ -78,14 +80,16 @@ jobs:

build_wheels:
if: >-
github.event_name == 'push' ||
github.event_name == 'pull_request' && (
(
github.event.action == 'labeled' &&
github.event.label.name == 'CI: Run cibuildwheel'
) ||
contains(github.event.pull_request.labels.*.name,
'CI: Run cibuildwheel')
github.repository == 'matplotlib/matplotlib' && (
github.event_name == 'push' ||
github.event_name == 'pull_request' && (
(
github.event.action == 'labeled' &&
github.event.label.name == 'CI: Run cibuildwheel'
) ||
contains(github.event.pull_request.labels.*.name,
'CI: Run cibuildwheel')
)
)
needs: build_sdist
name: Build wheels on ${{ matrix.os }} for ${{ matrix.cibw_archs }}
Expand Down Expand Up @@ -188,7 +192,7 @@ jobs:
if-no-files-found: error

publish:
if: github.event_name == 'push' && github.ref_type == 'tag'
if: github.repository == 'matplotlib/matplotlib' && github.event_name == 'push' && github.ref_type == 'tag'
name: Upload release to PyPI
needs: [build_sdist, build_wheels]
runs-on: ubuntu-latest
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:

jobs:
analyze:
if: github.repository == 'matplotlib/matplotlib'
name: Analyze
runs-on: ubuntu-latest
permissions:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/conflictcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ on:

jobs:
main:
if: github.repository == 'matplotlib/matplotlib'
runs-on: ubuntu-latest
permissions:
pull-requests: write
Expand Down
Loading