Can't install nodejs version using nvm in Mac os
In case if you want to run rosetta apps multiple times in your current shell, you can prepend the following line:
env /usr/bin/arch -x86_64 /bin/zsh --login
# ...
nvm install 10
# Do all the x86_64 commands you want including building stuff using node-gpy
This will enter a "rosetta mode" in terminal from which you can quit just by typing exit
in terminal
You can create an alias for that. By running the following command you will add alias x86
which will log into your rosette terminal once you type it
echo 'alias x86="env /usr/bin/arch -x86_64 /bin/zsh --login"' >> ~/.zshrc
the solution for me was to prefix each command by arch -x86_64
so in my case it was arch -x86_64 nvm install 10.6.0
some people also suggest opening terminal in rosetta
mode