svierk/Get Node Version
Pulls the Node.js version to be used from the package.json file of a project, with an optional input to override it.
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| node-version | Explicit Node.js version spec that takes precedence over the package.json lookup. An empty value (e.g. an unset repository variable) falls back to package.json. | no | "" |
| path | Specify the path where the package.json file can be found. | no | ./ |
| package-manager | Specify the package manager to be used. Supported values: npm, yarn, pnpm | no | npm |
| step-summary | Write a result section to the GitHub Actions job summary. Set to false to avoid collisions with a custom workflow summary. | no | true |
Outputs
| name | description |
|---|---|
| node-version | The Node.js version spec resolved from the node-version input or the package.json engines field. |
| source | Where the version spec was resolved from: "node-version input" or "package.json". |