diff --git a/install-gui.sh b/install-gui.sh index 813864142117..7467fba433cc 100755 --- a/install-gui.sh +++ b/install-gui.sh @@ -163,7 +163,17 @@ elif [ "$(uname)" = "Darwin" ] && type brew >/dev/null 2>&1; then # MacOS if ! nodejs_is_installed; then echo "Installing nodejs on MacOS" - brew install npm + # Download and install nvm: + curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash + # in lieu of restarting the shell + # shellcheck source=/dev/null + source "$HOME/.nvm/nvm.sh" + # Download and install Node.js: + nvm install 20 + echo "Node version" + node -v + echo "npm version:" + npm -v fi do_install_npm_locally elif [ "$(uname)" = "OpenBSD" ]; then