I just got an m1 Mac and installed anaconda using home-brew:
brew install anaconda
It looked like it worked great, except that when I actually go to use anaconda and type "conda" I get the dreaded "conda command not found" error. How do I fix this?
Based on the answer given by @Peter here as well as the anaconda documentation, adding to path is no longer recommended. The answers here also did not solve the problem.
Figured it out! Challenge lay in the home-brew path. To run the conda init zsh command, detailed by @Sebastian in the answer here, I had to specify home-brew, as well as back up a couple directories. The command that actually got it done in terminal was:
/opt/homebrew/anaconda3/bin/conda init zsh
Happy home-brew anaconda-ing on your new m1s everyone.
I ran into this same issue when installing condo on my Mac M2 with brew e.g. homebrew.
Complete list of steps I ran, to resolve that:
$ brew install anaconda
...
PREFIX=/opt/homebrew/anaconda3
...
$ /opt/homebrew/anaconda3/bin/conda init $(basename $SHELL)
modified /Users/ritvik/.zshrc
==> For changes to take effect, close and re-open your current shell. <==
N.B. when running brew install anaconda, brew itself prints the folder path to anaconda installation in the terminal. You can see it in above:
PREFIX=/opt/homebrew/anaconda3
Just tack on a /bin/conda to that directory, and one will locate the condo executable path.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With