Skip to content

check corepack

check corepack #53

Workflow file for this run

name: Test final
on:
push:
branches:
- test-1222
workflow_dispatch:
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.18.2'
registry-url: 'https://registry.npmjs.org'
- name: check corepack version
run: |
corepack --version
- name: Check location of corepack
run: |
C:\Windows\System32\where.exe corepack
- name: Clear npm cache
run: |
npm cache clean --force
- name: Install latest corepack version globally
run: |
npm install --global --force corepack@latest
- name: Modify PATH to prioritize global npm bin directory
run: |
$env:PATH = "C:\\npm\\prefix;" + $env:PATH
[System.Environment]::SetEnvironmentVariable("PATH", $env:PATH, [System.EnvironmentVariableTarget]::Process)
echo $env:PATH
# This step explicitly moves the global npm bin directory to the front.
- name: Check location of corepack
run: |
C:\Windows\System32\where.exe corepack
- name: check corepack version
run: |
corepack --version
# - name: Run pnpm install
# run: pnpm install