Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
# author: khanhtc
# script for installing nodejs from source
OS=$(uname -s | awk '{print tolower($0)}')
ARCH=$(uname -m | sed 's/x86_/x/g')
RSHELL=$(echo $SHELL | sed 's/\/bin\///g')
wget "${VERSION}/${PKG_NAME}"
tar -xzf ${PKG_NAME}
sudo mv $(basename ${PKG_NAME} .tar.gz)/ /usr/local/node
echo "export PATH=$PATH:/usr/local/node/bin" >> ~/.${RSHELL}rc
rm -rf ${PKG_NAME}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.