re-re-fixed custom npm path detection

This commit is contained in:
Eugene Pankov 2017-07-05 21:13:41 +02:00
parent c087a969d6
commit a6f7f7aa05

View File

@ -41,6 +41,9 @@ export class PluginManagerService {
async detectPath () {
this.npmPath = this.config.store.npm
if (await fs.exists(this.npmPath)) {
return
}
if (this.hostApp.platform !== Platform.Windows) {
let searchPaths = (await exec('bash -c -l "echo $PATH"'))[0].toString().trim().split(':')
for (let searchPath of searchPaths) {