I installed anaconda3 into my home directory. This is what I am seeing within the terminal:
and my .bash_profile looks like this:
export PATH="/Users/spotter/anaconda3/bin:$PATH"
So I don't understand why conda is not being recognized. When I navigate to anaconda3/bin there is a file called conda
in there, but even when I try to call it within that pathway it is still not found.
in Mac OS, for conda >4,4, the conventional way of exporting path (
export PATH="Users/myuser/anaconda3/bin:$PATH"
) is NOT recommended anymore. First, see what is error message in your terminal in Mac when you typeconda --version
. If it sayszsh conda not found
then you are using ZSH terminal, so modifying any bash file is useless. In this case, you need to edit your.zprofile
. on the other hand, if you get error likebash conda not found
you edit.bash_profile
. Lets, say we have zsh error, then type in terminal:located your
conda.sh
file by searching in your finder. Most probably it is in~/anaconda3/etc/profile.d/conda.sh
(for me it was like:/Users/hasbah/opt/anaconda3/etc/profile.d/conda.sh
, but instead of anaconda3, it might be conda)then you type in
.zhprfile
this:then you save (ctrl+X and Y when was asked to save) and restart the terminal. Now if you type
conda --version
you will see it. so, in short:I had to type
source ~/anaconda3/bin/activate
.For anyone that landed here that is using a non-standard shell (zsh for example) the installer 5.3.1 currently changes the bash_profile not the current active default terminal.
Just open ~/.bash_profile, find the block that is added by the installer and copy it into your .zshrc file (if using zsh)
Rather than adding the
~/anaconda3/bin
to yourPATH
, you should addto your
.bash_profile
or.bashrc
, or type that in a shell, if you don't want it to be activated for each shell. This is the recommended way to activate conda since conda 4.4. See: https://github.com/conda/conda/blob/master/CHANGELOG.md#440-2017-12-20Spotter, your path to conda is incorrect.
I'm on High Sierra MAC OS and just installed Anaconda3 via HomeBrew command. I had issue with running :
It'd also give me:
I tried running:
but it needs ENTIRE path. so here are the correct steps:
Now export the ENTIRE path, in my case it was:
Exit out and run:
Then try:
it'll output: