You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is frequently important to have the runtime node version match the version used locally and in CI (e.g. to run tests). Similarly to how the setup-node or asdf-vm/actions/install actions work in GitHub Actions, it should be possible for hedy to read the node version from a file so that the following are controlled in one place:
GitHub Actions (e.g. via the setup-node or asdf-vm/actions/install action)
Runtime version
Proposed Syntax
node-version-file CLI argument and nodeVersionFile package configuration should be able to contain a relative file path. If present and the file contains a parseable value, this should be used as the node version. If the value is a simple integer, that's the node version. If the value contains a two or three segment version (i.e. 20.1.2) then only the first segment is used.
Similar to the setup-node action, if both node-version-file and node-version are configured, node-version is used.
The text was updated successfully, but these errors were encountered:
I think engines means something slightly different -- that is intended to represent a range of versions that can be used whereas .node-version (when used with a version manager), setup-node/node-version and node-version in hedy configuration say "this is the version to use"
Ah, I understand now. Yes, that provides some locality. And TBH if it was just a matter of GitHub Actions + hedy this wouldn't be necessary since you can extract the version set up by the setup-node action as an output and use it to generate a HLX_NODE_VERSION environment variable.
But this leaves local execution out. I clarified this in my original message.
Expected Behaviour
It is frequently important to have the runtime node version match the version used locally and in CI (e.g. to run tests). Similarly to how the
setup-node
orasdf-vm/actions/install
actions work in GitHub Actions, it should be possible for hedy to read the node version from a file so that the following are controlled in one place:setup-node
orasdf-vm/actions/install
action)Proposed Syntax
node-version-file
CLI argument andnodeVersionFile
package configuration should be able to contain a relative file path. If present and the file contains a parseable value, this should be used as the node version. If the value is a simple integer, that's the node version. If the value contains a two or three segment version (i.e.20.1.2
) then only the first segment is used.Similar to the
setup-node
action, if bothnode-version-file
andnode-version
are configured,node-version
is used.The text was updated successfully, but these errors were encountered: