material: Only run docs deploy on changes to /docs (https://github.com/slint-ui/material-components/issues/16)

Imported from 43fd569583
This commit is contained in:
Nigel Breslaw 2025-06-17 13:12:52 +03:00 committed by Olivier Goffart
parent 2a30bbada4
commit cb505c61db

View file

@ -35,13 +35,29 @@ jobs:
- name: Format, lint and REUSE check
uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27
filter_docs_changes:
runs-on: ubuntu-latest
needs: [format_fix]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Filter changes
id: changes
uses: dorny/paths-filter@v3
with:
filters: |
docs:
- 'docs/**'
deploy:
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
name: Deploy to Cloudflare Pages
needs: format_fix
needs: [filter_docs_changes]
if: needs.filter_docs_changes.outputs.docs == 'true'
defaults:
run:
working-directory: docs