Skip to content

Latest commit

 

History

History
49 lines (31 loc) · 2.31 KB

File metadata and controls

49 lines (31 loc) · 2.31 KB

setup-nodejs-context

Sets up a specific NodeJS version and installs pnpm as well as the dependencies listed in package.json; any of these steps can be skipped by disabling the related flag.

Example

steps:
  - uses: actions/checkout@v4

  - uses: giancosta86/aurora-github/actions/setup-nodejs-context@v5

Please, note: this action is automatically run by verify-npm-package and publish-npm-package.

Requirements

The project directory must contain:

  • the .nvmrc file, containing the expected NodeJS version, as expected by nvm - if setup-nodejs is set to true

  • the package.json descriptor, if install-dependencies is set to true

  • an updated pnpm-lock.yaml file, if both install-dependencies and frozen-lockfile are enabled

Inputs 📥

Name Type Description Default value
setup-nodejs boolean Set up the requested NodeJS version true
install-pnpm boolean Install the requested pnpm version true
install-dependencies boolean Install the dependencies for the current package true
pnpm-version string The version of pnpm to use 9
registry-url string The URL of the npm registry Official npm registry
frozen-lockfile boolean Fail if "pnpm-lock.yaml" is missing or outdated true
project-directory string The directory containing package.json .
shell string The shell used to run commands bash

Further references