docs: Node version file: Clarify effect of version range in engines.node
Description:
In docs/advanced-usage.md#node-version-file, explain what effect "engines": { "node": ">=16.0.0" } would have had if it was not overridden by the volta option.
Justification: I cannot tell from reading whether the example would install node 16, 20, 21 or 22.
Are you willing to submit a PR? Yes.
Hello @mk-pmb We appreciate your suggestion for a new feature! We'll make sure to address it when we have the opportunity
Hi @mk-pmb 👋, thank you for your feedback!
When "engines": { "node": ">=16.0.0" } is specified and not overridden by volta.node, the action will install the highest available version that satisfies this range, in line with SemVer guidelines. This could include versions like 16.x, 18.x, 20.x, or any newer version that meets the requirement.
For more details on how version matching works, please refer to the SemVer documentation on ranges.
I hope this clears things up! Please feel free to reach out if you have further questions or suggestions. We truly appreciate your input!
Thanks for the clarification! Next step would be to check if the example in the file still is confusing, and if so, add the clarification there. Maybe I can do that soon.
@mk-pmb 👋, Sounds great — really appreciate your initiative on this! If anything feels unclear while reviewing the example or if you think something could use more context, feel free to let us know. We're happy to help clarify or collaborate on improvements.
@mk-pmb,
Thanks for the suggestion! As discussed in PR #1284, we’ve decided not to add the npm docs link, as the use of engines.node with the setup-node action is already well-documented. To keep the documentation focused and relevant to this action, we’re closing this issue. Feel free to reach out with any further suggestions!