CI: minor speed boost for Check Asset Sizes and Build Project Jobs. (#50342)

This commit is contained in:
Vladimir Reznichenko 2024-08-05 12:58:39 +02:00 committed by GitHub
parent 854c81d9ad
commit 559c91626c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 6 additions and 13 deletions

View File

@ -40,10 +40,8 @@ jobs:
with: with:
# If 'base_ref' is available, the 'Build Matrix' step requires non-shallow git-history to identify changed files. # If 'base_ref' is available, the 'Build Matrix' step requires non-shallow git-history to identify changed files.
fetch-depth: ${{ ( ( github.base_ref && '0' ) || '1' ) }} fetch-depth: ${{ ( ( github.base_ref && '0' ) || '1' ) }}
- uses: './.github/actions/setup-woocommerce-monorepo' - name: 'Setup PNPM'
name: 'Setup Monorepo' uses: 'pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d'
with:
php-version: false # We don't want to waste time installing PHP since we aren't using it in this job.
- uses: actions/github-script@v7 - uses: actions/github-script@v7
name: 'Build Matrix' name: 'Build Matrix'
id: 'project-jobs' id: 'project-jobs'
@ -254,10 +252,8 @@ jobs:
- uses: 'actions/checkout@v4' - uses: 'actions/checkout@v4'
name: 'Checkout' name: 'Checkout'
- uses: './.github/actions/setup-woocommerce-monorepo' - name: 'Setup PNPM'
name: 'Setup Monorepo' uses: 'pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d'
with:
php-version: false
- name: 'Send messages for failed jobs' - name: 'Send messages for failed jobs'
env: env:

View File

@ -41,9 +41,7 @@ jobs:
- name: Setup WooCommerce Monorepo - name: Setup WooCommerce Monorepo
uses: ./.github/actions/setup-woocommerce-monorepo uses: ./.github/actions/setup-woocommerce-monorepo
with: with:
# Both install and build are handled by compressed-size-action. php-version: false
install: false
build: false
pull-package-deps: '@woocommerce/plugin-woocommerce' pull-package-deps: '@woocommerce/plugin-woocommerce'
- uses: preactjs/compressed-size-action@f780fd104362cfce9e118f9198df2ee37d12946c - uses: preactjs/compressed-size-action@f780fd104362cfce9e118f9198df2ee37d12946c

View File

@ -39,8 +39,6 @@ jobs:
- name: Setup PNPM - name: Setup PNPM
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2
with:
version: '8.6.7'
- name: Setup Node - name: Setup Node
uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c

View File

@ -3,6 +3,7 @@
"title": "WooCommerce Monorepo", "title": "WooCommerce Monorepo",
"description": "Monorepo for the WooCommerce ecosystem", "description": "Monorepo for the WooCommerce ecosystem",
"homepage": "https://woocommerce.com/", "homepage": "https://woocommerce.com/",
"packageManager": "pnpm@^9.1.0",
"engines": { "engines": {
"node": "^20.11.1", "node": "^20.11.1",
"pnpm": "^9.1.0" "pnpm": "^9.1.0"