2021-02-18 11:13:51 +01:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
|
|
|
if echo "$OSTYPE" | grep -qE '^linux-gnu.*' && [ -f '/etc/debian_version' ]; then
|
|
|
|
PKGMGR="sudo apt-get"
|
|
|
|
else
|
|
|
|
PKGMGR="pkg"
|
|
|
|
fi
|
|
|
|
|
|
|
|
## Install Python, Wget and cURL
|
|
|
|
if echo "$OSTYPE" | grep -qE '^linux-android.*'; then
|
|
|
|
$PKGMGR install python nodejs-lts nano wget git -y
|
|
|
|
else
|
|
|
|
$PKGMGR install python3 python3-dev python3-pip nano curl wget -y
|
|
|
|
fi
|
|
|
|
|
|
|
|
## Then, install Node.js using nvm
|
2021-03-28 14:35:12 +02:00
|
|
|
|
|
|
|
NODEJS_INSTALL_PATH=$(command -v node)
|
|
|
|
if [[ $NODEJS_INSTALL_PATH == "" ]]; then
|
|
|
|
true
|
|
|
|
else
|
|
|
|
echo "info: Node.js is installed, skipping..."
|
2021-02-18 11:13:51 +01:00
|
|
|
fi
|