Closed jaredstehler closed 1 year ago
currently, if you specify a provided nodePath and npmPath, the prettier downloader invokes npmPath directly, which requires node on the PATH.
nodePath
npmPath
node
PATH
updates the npm command to use the provided nodePath, if the provided npmPath references an npm-cli.js. this matches the logic which uses the downloaded node runtime for npm: https://github.com/HubSpot/prettier-maven-plugin/blob/7104b57ae1d17cbf46fe114dfbef12ca8a3cd88e/prettier-maven-plugin/src/main/java/com/hubspot/maven/plugins/prettier/internal/OperatingSystemFamily.java#L88-L91
npm-cli.js
@stevie400 @Xcelled @suruuK @kmclarnon
currently, if you specify a provided
nodePath
andnpmPath
, the prettier downloader invokesnpmPath
directly, which requiresnode
on thePATH
.updates the npm command to use the provided
nodePath
, if the providednpmPath
references annpm-cli.js
. this matches the logic which uses the downloaded node runtime for npm: https://github.com/HubSpot/prettier-maven-plugin/blob/7104b57ae1d17cbf46fe114dfbef12ca8a3cd88e/prettier-maven-plugin/src/main/java/com/hubspot/maven/plugins/prettier/internal/OperatingSystemFamily.java#L88-L91@stevie400 @Xcelled @suruuK @kmclarnon