Fix npm executable path resolution in build script
This commit is contained in:
parent
e6df93ff5c
commit
6f2a48338b
|
|
@ -42,7 +42,7 @@ tasks.register("npmBuild") {
|
|||
commandLine(npmCmd, "run", "build")
|
||||
} else {
|
||||
val npmExecutable = file(nodeDir).listFiles()?.find { it.name.startsWith("npm") && it.isDirectory }?.let {
|
||||
"${it.absolutePath}/bin/npm/"
|
||||
"${it.absolutePath}/bin/npm"
|
||||
} ?: "$nodeDir/node_modules/npm/bin/npm"
|
||||
|
||||
commandLine(npmExecutable, "run", "build")
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user