ci: refer .npmrc to ensure using consistent node version (#3228)

This commit is contained in:
TAKAHASHI Shuuji 2025-03-07 01:18:29 +09:00 committed by GitHub
parent 54265dab29
commit 538064589d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 4 additions and 2 deletions

View file

@ -23,6 +23,8 @@ jobs:
# - https://github.com/nodejs/corepack/issues/612#issuecomment-2629496091
- run: npm i -g corepack@latest && corepack enable
- uses: actions/setup-node@v4.2.0
with:
node-version-file: .nvmrc
- name: 📦 Install dependencies
run: pnpm install --frozen-lockfile

View file

@ -19,7 +19,7 @@ jobs:
- name: Set node
uses: actions/setup-node@v4
with:
node-version: 18
node-version-file: .nvmrc
- run: npx changelogithub
env:

View file

@ -18,7 +18,7 @@ To develop and test the Elk package:
1. Fork the Elk repository to your own GitHub account and then clone it to your local device.
2. Ensure using the latest Node.js (20.x).
2. Ensure using the LTS version of Node.js.
If you have [nvm](https://github.com/nvm-sh/nvm), you can run `nvm i` to install the required version.
3. The package manager used to install and link dependencies must be [pnpm](https://pnpm.io/) v9. To use it you must first enable [Corepack](https://github.com/nodejs/corepack) by running `corepack enable`. (Note: on Linux in a standard Node 20+ environment, you should follow the instructions to install via Node's `corepack` rather than using the `curl` command)