mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-04-12 04:33:29 +08:00
fix(ci): enable Corepack for yarn and relax pnpm strict mode
All 18 pnpm/yarn CI jobs fail on main because: 1. pnpm v9+ refuses to install when package.json declares "packageManager": "yarn@4.9.2" — fixed by setting COREPACK_ENABLE_STRICT=0 and --no-frozen-lockfile 2. CI runners only have Yarn Classic (v1.x) but the project uses Yarn Berry (v4.x) — fixed by activating Corepack before the cache/install steps
This commit is contained in:
13
.github/workflows/ci.yml
vendored
13
.github/workflows/ci.yml
vendored
@@ -48,6 +48,13 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: latest
|
version: latest
|
||||||
|
|
||||||
|
- name: Setup Yarn (via Corepack)
|
||||||
|
if: matrix.pm == 'yarn'
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
corepack enable
|
||||||
|
corepack prepare yarn@stable --activate
|
||||||
|
|
||||||
- name: Setup Bun
|
- name: Setup Bun
|
||||||
if: matrix.pm == 'bun'
|
if: matrix.pm == 'bun'
|
||||||
uses: oven-sh/setup-bun@v2
|
uses: oven-sh/setup-bun@v2
|
||||||
@@ -114,12 +121,16 @@ jobs:
|
|||||||
${{ runner.os }}-bun-
|
${{ runner.os }}-bun-
|
||||||
|
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
|
# COREPACK_ENABLE_STRICT=0 allows pnpm to install even though
|
||||||
|
# package.json declares "packageManager": "yarn@..."
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
shell: bash
|
shell: bash
|
||||||
|
env:
|
||||||
|
COREPACK_ENABLE_STRICT: '0'
|
||||||
run: |
|
run: |
|
||||||
case "${{ matrix.pm }}" in
|
case "${{ matrix.pm }}" in
|
||||||
npm) npm ci ;;
|
npm) npm ci ;;
|
||||||
pnpm) pnpm install ;;
|
pnpm) pnpm install --no-frozen-lockfile ;;
|
||||||
# --ignore-engines required for Node 18 compat with some devDependencies (e.g., markdownlint-cli)
|
# --ignore-engines required for Node 18 compat with some devDependencies (e.g., markdownlint-cli)
|
||||||
yarn) yarn install --ignore-engines ;;
|
yarn) yarn install --ignore-engines ;;
|
||||||
bun) bun install ;;
|
bun) bun install ;;
|
||||||
|
|||||||
13
.github/workflows/reusable-test.yml
vendored
13
.github/workflows/reusable-test.yml
vendored
@@ -40,6 +40,13 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: latest
|
version: latest
|
||||||
|
|
||||||
|
- name: Setup Yarn (via Corepack)
|
||||||
|
if: inputs.package-manager == 'yarn'
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
corepack enable
|
||||||
|
corepack prepare yarn@stable --activate
|
||||||
|
|
||||||
- name: Setup Bun
|
- name: Setup Bun
|
||||||
if: inputs.package-manager == 'bun'
|
if: inputs.package-manager == 'bun'
|
||||||
uses: oven-sh/setup-bun@v2
|
uses: oven-sh/setup-bun@v2
|
||||||
@@ -104,12 +111,16 @@ jobs:
|
|||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-bun-
|
${{ runner.os }}-bun-
|
||||||
|
|
||||||
|
# COREPACK_ENABLE_STRICT=0 allows pnpm to install even though
|
||||||
|
# package.json declares "packageManager": "yarn@..."
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
shell: bash
|
shell: bash
|
||||||
|
env:
|
||||||
|
COREPACK_ENABLE_STRICT: '0'
|
||||||
run: |
|
run: |
|
||||||
case "${{ inputs.package-manager }}" in
|
case "${{ inputs.package-manager }}" in
|
||||||
npm) npm ci ;;
|
npm) npm ci ;;
|
||||||
pnpm) pnpm install ;;
|
pnpm) pnpm install --no-frozen-lockfile ;;
|
||||||
yarn) yarn install --ignore-engines ;;
|
yarn) yarn install --ignore-engines ;;
|
||||||
bun) bun install ;;
|
bun) bun install ;;
|
||||||
*) echo "Unsupported package manager: ${{ inputs.package-manager }}" && exit 1 ;;
|
*) echo "Unsupported package manager: ${{ inputs.package-manager }}" && exit 1 ;;
|
||||||
|
|||||||
Reference in New Issue
Block a user