Skip to content

Commit

Permalink
Use nvm 0.39.7
Browse files Browse the repository at this point in the history
  • Loading branch information
kabalin committed Aug 9, 2024
1 parent 3842ad1 commit c67a34c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,10 @@ jobs:
# PHPUnit depends on en_AU.UTF-8 locale
sudo locale-gen en_AU.UTF-8
# Define NVM_DIR pointing to nvm installation.
echo "NVM_DIR=$HOME/.nvm" >> $GITHUB_ENV
mkdir "$HOME/.nvm39"
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | NVM_DIR="$HOME/.nvm39" bash
echo "NVM_DIR=$HOME/.nvm39" >> $GITHUB_ENV
source ~/.nvm39/nvm.sh && nvm --version
- name: Install moodle-plugin-ci
run: moodle-plugin-ci install -vvv
Expand Down
2 changes: 1 addition & 1 deletion src/Installer/VendorInstaller.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public function installNode(): void
}

$nvmDir = getenv('NVM_DIR');
$cmd = ". $nvmDir/nvm.sh && nvm install && nvm use && echo \"NVM_BIN=\$NVM_BIN\"";
$cmd = "source $nvmDir/nvm.sh && nvm --version && nvm install && nvm use && echo \"NVM_BIN=\$NVM_BIN\"";

$process = $this->execute->passThroughProcess(
Process::fromShellCommandline($cmd, $this->moodle->directory, null, null, null)
Expand Down

0 comments on commit c67a34c

Please sign in to comment.