ci: populate workspace workflows #40
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI/CD | |
on: | |
push: | |
workflow_dispatch: | |
concurrency: | |
group: "${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}" | |
cancel-in-progress: true | |
jobs: | |
changes: | |
name: Detect affected workspaces | |
runs-on: ubuntu-latest | |
outputs: | |
eslint-config-scratch: ${{ steps.filter.outputs.eslint-config-scratch }} | |
scratch-audio: ${{ steps.filter.outputs.scratch-audio }} | |
scratch-l10n: ${{ steps.filter.outputs.scratch-l10n }} | |
scratch-paint: ${{ steps.filter.outputs.scratch-paint }} | |
scratch-parser: ${{ steps.filter.outputs.scratch-parser }} | |
scratch-svg-renderer: ${{ steps.filter.outputs.scratch-svg-renderer }} | |
scratch-render: ${{ steps.filter.outputs.scratch-render }} | |
scratch-sb1-converter: ${{ steps.filter.outputs.scratch-sb1-converter }} | |
scratch-storage: ${{ steps.filter.outputs.scratch-storage }} | |
scratch-vm: ${{ steps.filter.outputs.scratch-vm }} | |
scratch-gui: ${{ steps.filter.outputs.scratch-gui }} | |
scratch-semantic-release-config: ${{ steps.filter.outputs.scratch-semantic-release-config }} | |
scratch-translate-extension-languages: ${{ steps.filter.outputs.scratch-translate-extension-languages }} | |
steps: | |
- uses: actions/checkout@v4 # TODO: skip this for PRs | |
- uses: dorny/paths-filter@v2 | |
id: filter | |
with: | |
filters: | | |
any-workspace: | |
- ".github/workflows/workspace-*.yml" | |
- "workspaces/**" | |
eslint-config-scratch: | |
- ".github/workflows/workspace-eslint-config-scratch.yml" | |
- "workspaces/eslint-config-scratch/**" | |
scratch-audio: | |
- ".github/workflows/workspace-scratch-audio.yml" | |
- "workspaces/scratch-audio/**" | |
scratch-l10n: | |
- ".github/workflows/workspace-scratch-l10n.yml" | |
- "workspaces/scratch-l10n/**" | |
scratch-paint: | |
- ".github/workflows/workspace-scratch-paint.yml" | |
- "workspaces/scratch-paint/**" | |
scratch-parser: | |
- ".github/workflows/workspace-scratch-parser.yml" | |
- "workspaces/scratch-parser/**" | |
scratch-svg-renderer: | |
- ".github/workflows/workspace-scratch-svg-renderer.yml" | |
- "workspaces/scratch-svg-renderer/**" | |
scratch-render: | |
- ".github/workflows/workspace-scratch-render.yml" | |
- "workspaces/scratch-render/**" | |
- "workspaces/scratch-svg-renderer/**" | |
scratch-sb1-converter: | |
- ".github/workflows/workspace-scratch-sb1-converter.yml" | |
- "workspaces/scratch-sb1-converter/**" | |
scratch-storage: | |
- ".github/workflows/workspace-scratch-storage.yml" | |
- "workspaces/scratch-storage/**" | |
scratch-vm: | |
- ".github/workflows/workspace-scratch-vm.yml" | |
- "workspaces/scratch-audio/**" | |
- "workspaces/scratch-parser/**" | |
- "workspaces/scratch-render/**" | |
- "workspaces/scratch-sb1-converter/**" | |
- "workspaces/scratch-storage/**" | |
- "workspaces/scratch-svg-renderer/**" | |
- "workspaces/scratch-translate-extension-languages/**" | |
- "workspaces/scratch-vm/**" | |
scratch-gui: | |
- ".github/workflows/workspace-scratch-gui.yml" | |
- "workspaces/scratch-audio/**" | |
- "workspaces/scratch-gui/**" | |
- "workspaces/scratch-l10n/**" | |
- "workspaces/scratch-paint/**" | |
- "workspaces/scratch-parser/**" | |
- "workspaces/scratch-render/**" | |
- "workspaces/scratch-sb1-converter/**" | |
- "workspaces/scratch-storage/**" | |
- "workspaces/scratch-svg-renderer/**" | |
- "workspaces/scratch-translate-extension-languages/**" | |
- "workspaces/scratch-vm/**" | |
scratch-semantic-release-config: | |
- ".github/workflows/workspace-scratch-semantic-release-config.yml" | |
- "workspaces/scratch-semantic-release-config/**" | |
scratch-translate-extension-languages: | |
- ".github/workflows/workspace-scratch-translate-extension-languages.yml" | |
- "workspaces/scratch-translate-extension-languages/**" | |
- if: ${{ steps.filter.outputs.any-workspace == 'true' }} | |
uses: actions/setup-node@v3 | |
with: | |
cache: npm | |
node-version-file: .nvmrc | |
- if: ${{ steps.filter.outputs.any-workspace == 'true' }} | |
uses: ./.github/actions/install-dependencies | |
eslint-config-scratch: | |
uses: ./.github/workflows/workspace-eslint-config-scratch.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.eslint-config-scratch == 'true' }} | |
needs: | |
- changes | |
scratch-audio: | |
uses: ./.github/workflows/workspace-scratch-audio.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-audio == 'true' }} | |
needs: | |
- changes | |
scratch-l10n: | |
uses: ./.github/workflows/workspace-scratch-l10n.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-l10n == 'true' }} | |
needs: | |
- changes | |
scratch-paint: | |
uses: ./.github/workflows/workspace-scratch-paint.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-paint == 'true' }} | |
needs: | |
- changes | |
scratch-parser: | |
uses: ./.github/workflows/workspace-scratch-parser.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-parser == 'true' }} | |
needs: | |
- changes | |
scratch-svg-renderer: | |
uses: ./.github/workflows/workspace-scratch-svg-renderer.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-svg-renderer == 'true' }} | |
needs: | |
- changes | |
scratch-render: | |
uses: ./.github/workflows/workspace-scratch-render.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-render == 'true' }} | |
needs: | |
- changes | |
- scratch-svg-renderer | |
scratch-sb1-converter: | |
uses: ./.github/workflows/workspace-scratch-sb1-converter.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-sb1-converter == 'true' }} | |
needs: | |
- changes | |
scratch-storage: | |
uses: ./.github/workflows/workspace-scratch-storage.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-storage == 'true' }} | |
needs: | |
- changes | |
scratch-vm: | |
uses: ./.github/workflows/workspace-scratch-vm.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-vm == 'true' }} | |
needs: | |
- changes | |
- scratch-audio | |
- scratch-parser | |
- scratch-render | |
- scratch-sb1-converter | |
- scratch-storage | |
- scratch-svg-renderer | |
- scratch-translate-extension-languages | |
scratch-gui: | |
uses: ./.github/workflows/workspace-scratch-gui.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-gui == 'true' }} | |
needs: | |
- changes | |
- scratch-audio | |
- scratch-l10n | |
- scratch-paint | |
- scratch-parser | |
- scratch-render | |
- scratch-sb1-converter | |
- scratch-storage | |
- scratch-svg-renderer | |
- scratch-translate-extension-languages | |
- scratch-vm | |
scratch-semantic-release-config: | |
uses: ./.github/workflows/workspace-scratch-semantic-release-config.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-semantic-release-config == 'true' }} | |
needs: | |
- changes | |
scratch-translate-extension-languages: | |
uses: ./.github/workflows/workspace-scratch-translate-extension-languages.yml | |
if: ${{ !failure() && !cancelled() && needs.changes.outputs.scratch-translate-extension-languages == 'true' }} | |
needs: | |
- changes |