Skip to content
Open
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
23 changes: 19 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,29 @@ on:
pull_request:
branches: [ master, vnext ]

# A new push supersedes whatever is still running for the same PR, so cancel it
# rather than paying for eight jobs worth of results nobody will read. head_ref
# keeps the group per-PR; the fallback matters only if a push trigger is ever added.
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
build-and-verify:

runs-on: ubuntu-latest

strategy:
# Report every platform/language combination instead of stopping at the
# first failure — a JP-only break should not hide the EN results.
fail-fast: false
matrix:
platform: ['angular', 'react', 'webcomponents', 'blazor']
# Japanese is built as well as English because the two resolve content
# differently: docs/angular/astro.config.ts maps @xplat-images to
# src/content/<lang>/images, so an image that exists in EN does not
# satisfy a JP import, and an EN-only build never notices.
lang: ['en', 'jp']

steps:
- name: Checkout
Expand All @@ -30,13 +45,13 @@ jobs:

# DOCS_TOC_STRICT fails the build when a toc.json entry points at a
# missing file, instead of silently dropping it from the sidebar.
- name: Build ${{ matrix.platform }}
run: npm run xplat:build:${{ matrix.platform }}
- name: Build ${{ matrix.platform }} (${{ matrix.lang }})
run: npm run xplat:build:${{ matrix.platform }}${{ matrix.lang == 'jp' && ':jp' || '' }}
env:
DOCS_TOC_STRICT: 'true'

- name: Build Angular Unique
- name: Build Angular Unique (${{ matrix.lang }})
if: matrix.platform == 'angular'
run: npm run angular:build
run: npm run angular:build${{ matrix.lang == 'jp' && ':jp' || '' }}
env:
DOCS_TOC_STRICT: 'true'
Loading