Description:
- uses: actions/setup-node@v5
Currently this uses what's available in $PATH, but I reckon it should prefer what the user already specified as a compatible node version in the package.json.
Justification:
It feels strange that a project clearly and "natively" specifies what version it's expected to run on, but the environment ignores it, requiring further config.
I love that node-version-file: package.json is possible now, but I wish I didn't have to clutter all of my jobs with
- uses: actions/setup-node@v4
with:
node-version-file: package.json
. . .
- uses: actions/setup-node@v4
with:
node-version-file: package.json
. . .
- uses: actions/setup-node@v4
with:
node-version-file: package.json
The drawback is that in the rare situation where the user wants to use what's in PATH, as opposed to what's in package.json, now they'd need something like node-version: PATH. But again this feels like it should be the minority.
Are you willing to submit a PR?
Potentially
Description:
Currently this uses what's available in $PATH, but I reckon it should prefer what the user already specified as a compatible node version in the package.json.
Justification:
It feels strange that a project clearly and "natively" specifies what version it's expected to run on, but the environment ignores it, requiring further config.
I love that
node-version-file: package.jsonis possible now, but I wish I didn't have to clutter all of my jobs withThe drawback is that in the rare situation where the user wants to use what's in PATH, as opposed to what's in package.json, now they'd need something like
node-version: PATH. But again this feels like it should be the minority.Are you willing to submit a PR?
Potentially