mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-03-30 13:43:26 +08:00
Merge pull request #976 from ymdvsymd/fix/ci-pnpm-yarn-compat-v2
fix(ci): enable Corepack for yarn and relax pnpm strict mode
This commit is contained in:
17
.github/workflows/ci.yml
vendored
17
.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,14 +121,18 @@ 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)
|
# Yarn Berry (v4+) removed --ignore-engines; engine checking is no longer a core feature
|
||||||
yarn) yarn install --ignore-engines ;;
|
yarn) yarn install ;;
|
||||||
bun) bun install ;;
|
bun) bun install ;;
|
||||||
*) echo "Unsupported package manager: ${{ matrix.pm }}" && exit 1 ;;
|
*) echo "Unsupported package manager: ${{ matrix.pm }}" && exit 1 ;;
|
||||||
esac
|
esac
|
||||||
|
|||||||
16
.github/workflows/reusable-test.yml
vendored
16
.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,13 +111,18 @@ 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 Berry (v4+) removed --ignore-engines; engine checking is no longer a core feature
|
||||||
|
yarn) yarn install ;;
|
||||||
bun) bun install ;;
|
bun) bun install ;;
|
||||||
*) echo "Unsupported package manager: ${{ inputs.package-manager }}" && exit 1 ;;
|
*) echo "Unsupported package manager: ${{ inputs.package-manager }}" && exit 1 ;;
|
||||||
esac
|
esac
|
||||||
|
|||||||
Reference in New Issue
Block a user