ci: add path-based filtering to skip unnecessary builds (#319)
- unified-pipeline.yml: replace blanket .github/workflows/** glob with specific .github/workflows/unified-pipeline.yml in both web and python filters, so editing nightly.yml or release.yml no longer triggers the full lint/test/build matrix - distro-test-matrix.yml: add paths filter at workflow trigger level so the 4-container distro matrix only runs when installer, scripts, packaging, or version files change (previously ran on every push/PR including doc-only and web-only changes) Saves CI minutes on documentation, website, and unrelated workflow edits.
This commit is contained in:
@@ -3,8 +3,24 @@ name: Distro Test Matrix
|
||||
on:
|
||||
push:
|
||||
branches: [ main, master ]
|
||||
paths:
|
||||
- 'install.sh'
|
||||
- 'scripts/**'
|
||||
- 'pyproject.toml'
|
||||
- 'setup.py'
|
||||
- 'setup.cfg'
|
||||
- 'src/vocalinux/version.py'
|
||||
- '.github/workflows/distro-test-matrix.yml'
|
||||
pull_request:
|
||||
branches: [ main, master ]
|
||||
paths:
|
||||
- 'install.sh'
|
||||
- 'scripts/**'
|
||||
- 'pyproject.toml'
|
||||
- 'setup.py'
|
||||
- 'setup.cfg'
|
||||
- 'src/vocalinux/version.py'
|
||||
- '.github/workflows/distro-test-matrix.yml'
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
|
||||
@@ -32,7 +32,7 @@ jobs:
|
||||
filters: |
|
||||
web:
|
||||
- 'web/**'
|
||||
- '.github/workflows/**'
|
||||
- '.github/workflows/unified-pipeline.yml'
|
||||
python:
|
||||
- 'src/**'
|
||||
- 'tests/**'
|
||||
@@ -42,7 +42,7 @@ jobs:
|
||||
- 'requirements*.txt'
|
||||
- 'Makefile'
|
||||
- '.pre-commit-config.yaml'
|
||||
- '.github/workflows/**'
|
||||
- '.github/workflows/unified-pipeline.yml'
|
||||
- name: Check if website should deploy
|
||||
id: deploy_check
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user