diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8b549428..12753cf5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,6 +15,13 @@ jobs: matrix: lint_lang: [ 'lint-md', 'lint-js', 'lint-php' ] name: ${{ matrix.lint_lang }} + env: + # Auto-approve corepack's yarn download + COREPACK_ENABLE_DOWNLOAD_PROMPT: "0" + # Overrides any .yarnrc.yml so a forked pull-request cannot re-enable scripts + YARN_ENABLE_SCRIPTS: "false" + # Limit concurrent npm requests to avoid rate limiting in CI + YARN_NETWORK_CONCURRENCY: "1" steps: - name: Checkout code @@ -41,10 +48,12 @@ jobs: with: node-version: ${{ steps.read-nvm.outputs.version }} - - name: Install yarn + - name: Enable corepack if: ${{ matrix.lint_lang == 'lint-md' || matrix.lint_lang == 'lint-js' }} run: | - npm install --global yarn + # corepack is bundled with node 18 and provisions the yarn version declared in packageManager. + # Node 25+ does not bundle corepack - if node is bumped past 24, add npm install -g corepack first. + corepack enable - name: Run lint run: | diff --git a/.github/workflows/merge-up.yml b/.github/workflows/merge-up.yml index 84f0ba34..82e442dd 100644 --- a/.github/workflows/merge-up.yml +++ b/.github/workflows/merge-up.yml @@ -19,4 +19,4 @@ jobs: actions: write steps: - name: Merge-up - uses: silverstripe/gha-merge-up@v2 + uses: silverstripe/gha-merge-up@v3 diff --git a/.github/workflows/update-js.yml b/.github/workflows/update-js.yml index 7056de18..dc563984 100644 --- a/.github/workflows/update-js.yml +++ b/.github/workflows/update-js.yml @@ -14,4 +14,4 @@ jobs: runs-on: ubuntu-latest steps: - name: Update JS - uses: silverstripe/gha-update-js@v1 + uses: silverstripe/gha-update-js@v2 diff --git a/composer.json b/composer.json index d6cfc005..f2886027 100644 --- a/composer.json +++ b/composer.json @@ -21,7 +21,7 @@ } ], "require-dev": { - "silverstripe/documentation-lint": "^1" + "silverstripe/documentation-lint": "^2" }, "config": { "allow-plugins": {