mirror of
https://github.com/facebook/docusaurus.git
synced 2025-04-29 10:17:55 +02:00
chore(ci): run V1 Build and Migration CLI tests conditionally on CI (#3863)
* chore(ci): run V1 Build and Migration CLI test conditionally on CI * chore(ci): extend lighthouse timeout to 5 minutes * chore(ci): attempt to speed up build size check * chore(ci): use different build command in build size check * chore(ci): use only one locale in build size report workflow * chore(ci): fix quotes, move build-script param down
This commit is contained in:
parent
e90749c6f8
commit
99e3ee796e
5 changed files with 24 additions and 6 deletions
1
.github/workflows/build-size.yml
vendored
1
.github/workflows/build-size.yml
vendored
|
@ -13,6 +13,7 @@ jobs:
|
|||
- uses: preactjs/compressed-size-action@v2
|
||||
with:
|
||||
repo-token: '${{ secrets.GITHUB_TOKEN }}'
|
||||
build-script: 'build:v2:en'
|
||||
pattern: '{website/build/main*js,website/build/styles*css,website/build/index.html,website/build/blog/**/introducing-docusaurus/*,website/build/docs/introduction/index.html}'
|
||||
strip-hash: '\.([^;]\w{7})\.'
|
||||
minimum-change-threshold: 100
|
||||
|
|
1
.github/workflows/lighthouseCI.yml
vendored
1
.github/workflows/lighthouseCI.yml
vendored
|
@ -12,6 +12,7 @@ jobs:
|
|||
id: netlify
|
||||
with:
|
||||
site_name: 'docusaurus-2'
|
||||
max_timeout: 300
|
||||
- name: Audit URLs using Lighthouse
|
||||
id: lighthouse_audit
|
||||
uses: treosh/lighthouse-ci-action@v3
|
||||
|
|
16
.github/workflows/migration-cli-e2e-test.yml
vendored
16
.github/workflows/migration-cli-e2e-test.yml
vendored
|
@ -1,15 +1,25 @@
|
|||
name: Migration CLI E2E Test
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
check:
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
migration: ${{ steps.filter.outputs.migration }}
|
||||
steps:
|
||||
- uses: dorny/paths-filter@v2
|
||||
id: filter
|
||||
with:
|
||||
filters: |
|
||||
migration:
|
||||
- 'packages/docusaurus-migration/**'
|
||||
build:
|
||||
needs: check
|
||||
if: ${{ needs.check.outputs.migration == 'true' }}
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
|
|
11
.github/workflows/nodejs-windows.yml
vendored
11
.github/workflows/nodejs-windows.yml
vendored
|
@ -1,9 +1,6 @@
|
|||
name: Windows Build Test
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
|
@ -16,6 +13,13 @@ jobs:
|
|||
node: ['10']
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: dorny/paths-filter@v2
|
||||
id: filter
|
||||
with:
|
||||
filters: |
|
||||
v1:
|
||||
- 'packages/docusaurus-1.x/**'
|
||||
- 'packages/docusaurus-init-1.x/**'
|
||||
- name: Use Node.js ${{ matrix.node }}
|
||||
uses: actions/setup-node@v1
|
||||
with:
|
||||
|
@ -23,6 +27,7 @@ jobs:
|
|||
- name: Installation
|
||||
run: yarn || yarn || yarn # 3 attempts to avoid timeout errors...
|
||||
- name: Docusaurus 1 Build
|
||||
if: steps.filter.outputs.v1 == 'true'
|
||||
run: yarn build:v1
|
||||
- name: Docusaurus 2 Build
|
||||
run: yarn build:v2
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
"build:v2": "yarn workspace docusaurus-2-website build",
|
||||
"build:v2:baseUrl": "yarn workspace docusaurus-2-website build:baseUrl",
|
||||
"build:v2:blogOnly": "yarn workspace docusaurus-2-website build:blogOnly",
|
||||
"build:v2:en": "yarn workspace docusaurus-2-website build --locale en",
|
||||
"serve:v1": "serve website-1.x/build/docusaurus",
|
||||
"serve:v2": "yarn workspace docusaurus-2-website serve",
|
||||
"serve:v2:baseUrl": "serve website",
|
||||
|
|
Loading…
Add table
Reference in a new issue