Skip to content

Instantly share code, notes, and snippets.

@feliperodriguess
Created August 29, 2021 00:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save feliperodriguess/bafd591cc9d15898e63c22175a118743 to your computer and use it in GitHub Desktop.
Save feliperodriguess/bafd591cc9d15898e63c22175a118743 to your computer and use it in GitHub Desktop.
install nvm on MacBook M1 chips
# Install the most recent version of node or one that is at least v15
nvm install node
# Change to this new version
nvm use node
# Install Rosetta 2, if you haven't already
softwareupdate --install-rosetta
# Uninstall node v12 and v14, if you installed them before.
# Change the 'x's and 'y's to match the installed versions:
nvm uninstall 12.xx.x
nvm install 14.yy.y
# Open an x64 instance of zh:
arch -x86_64 zsh
# Install the desired Node versions and check if they are installed:
nvm install 12.xx.x
node -v
nvm install 14.yy.y
node -v
# Verify that you're still using an x64 shell:
node -p process.arch
# Exit the x64 instance:
exit
# Check that you-re back in an arm64 shell:
arch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment