Skip to content

Commit

Permalink
tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
kabalin committed Aug 21, 2024
1 parent c9cd817 commit 97f0c37
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Installer/VendorInstaller.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,11 +155,12 @@ public function installNode(): void
}

$nvmDir = getenv('NVM_DIR');
$cmd = ". $nvmDir/nvm.sh && nvm install && nvm use && echo \"NVM_BIN=\$NVM_BIN\"";
$cmd = ". {$this->moodle->directory}/.nvm/nvm.sh && nvm --version";

$process = $this->execute->passThroughProcess(
Process::fromShellCommandline($cmd, $this->moodle->directory, null, null, null)
);
echo $process->getOutput();
if (!$process->isSuccessful()) {
throw new \RuntimeException('Node.js installation failed.');
}
Expand Down

0 comments on commit 97f0c37

Please sign in to comment.