Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Conda command not found

People also ask

Why conda is not found?

Environment PATH for Conda is not set – This is the most common cause why this issue occurs. Keep in mind that the latest Anaconda builds will not automatically add Conda to your System variable paths since it can cause various issues with other software.

Why does my command prompt not recognize conda?

To Solve 'conda' is not recognized as internal or external command Error First of all you need to check conda installation path. Just Open Anaconda Prompt and type this command: where conda Then Press windows key and type Open Advanced System Settings. Now, Click on Environment Variables. Edit Path variable.


If you're using zsh and it has not been set up to read .bashrc, you need to add the Miniconda directory to the zsh shell PATH environment variable. Add this to your .zshrc:

export PATH="/home/username/miniconda/bin:$PATH"

Make sure to replace /home/username/miniconda with your actual path.

Save, exit the terminal and then reopen the terminal. conda command should work.


If you have the PATH in your .bashrc file and are still getting

conda: command not found

Your terminal might not be looking for the bash file. Type bash in the terminal to ensure you are in bash and then try: conda --version


For those experiencing issues after upgrading to MacOS Catalina.

Short version:

# 1a) Use tool: conda-prefix-replacement - 
# Restores: Desktop -> Relocated Items -> Security -> anaconda3
curl -L https://repo.anaconda.com/pkgs/misc/cpr-exec/cpr-0.1.1-osx-64.exe -o cpr && chmod +x cpr
./cpr rehome ~/anaconda3
# or if fails
#./cpr rehome ~/anaconda3 --old-prefix /Anaconda3
source ~/anaconda3/bin/activate

# 1b) Alternatively - reintall anaconda - 
# brew cask install anaconda

# 2) conda init
conda init zsh
# or
# conda init    

Further reading - Anaconda blog post and Github discussion.


Maybe you need to execute "source ~/.bashrc"


Sometimes, if you don't restart your terminal after you have installed anaconda also, it gives this error.

Close your terminal window and restart it.

It worked for me now!


Maybe you should type add this to your .bashrc or .zshrc

export PATH="/anaconda3/bin":$PATH

It worked for me.