| 1 | #!/bin/bash |
| 2 | set -e |
| 3 | |
| 4 | install_node() { |
| 5 | echo "Installing node..." |
| 6 | |
| 7 | curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.34.0/install.sh | bash |
| 8 | |
| 9 | source "$HOME"/.bashrc |
| 10 | |
| 11 | nvm install --no-progress 18 |
| 12 | } |
| 13 | |
| 14 | install_rust() { |
| 15 | echo "Installing rust..." |
| 16 | curl https://sh.rustup.rs -sSf | bash -s -- -y |
| 17 | export PATH="$PATH:/root/.cargo/bin" |
| 18 | } |
| 19 | |
| 20 | install_node |
| 21 | install_rust |