difference between command prompt and anaconda prompt

PythonCommand PromptAnaconda

Python Problem Overview


I installed anaconda into my computer using python. After I install the software, I found there is one program called anaconda prompt.

What is the difference between anaconda prompt and command prompt? If I want to update the package, which one I should use or either one. Like (conda update conda)

Thank you

Python Solutions


Solution 1 - Python

Anaconda command prompt is just like command prompt, but it makes sure that you are able to use anaconda and conda commands from the prompt, without having to change directories or your path.

When you start Anaconda command prompt, you'll notice that it adds/("prepends") a bunch of locations to your PATH. These locations contain commands and scripts that you can run. So as long as you're in the Anaconda command prompt, you know you can use these commands.

During the installation of Anaconda there is a choice to add these to the PATH by default, and if checked you can also use these commands on the regular command prompt. But the anaconda prompt will always work.

As far as updating conda, if it doesn't work in command prompt, you can do

conda update conda

in Anaconda command prompt.

Solution 2 - Python

When you use anaconda command prompt it opened at conda directory (path where all the conda commands run)

like when I was installing pip3 install prettytable on command prompt it successfully installed but not replicate in jupyter notebook. But when install it using anaconda prompt it replicates intantly

Solution 3 - Python

Here is the difference:

PATH-TO behind is the path to Anaconda3

Afer adding the following env to Windows command prompt, it will be the same as Anaconda prompt:

set CONDA_DEFAULT_ENV=base
set CONDA_PREFIX=PATH-TO\Anaconda3
set CONDA_EXE=%CONDA_PREFIX%\Scripts\conda.exe
set CONDA_PROMPT_MODIFIER=(base) 
set CONDA_PYTHON_EXE=%CONDA_PREFIX%\python.exe
set CONDA_SHLVL=1
set Path=%CONDA_PREFIX%;%CONDA_PREFIX%\Library\mingw-w64\bin;%CONDA_PREFIX%\Library\usr\bin;%CONDA_PREFIX%\Library\bin;%CONDA_PREFIX%\Scripts;%CONDA_PREFIX%\bin;%CONDA_PREFIX%\condabin;%Path%

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionMichael LiView Question on Stackoverflow
Solution 1 - PythonDylan OrzelView Answer on Stackoverflow
Solution 2 - PythonHimanshu kumar SinghView Answer on Stackoverflow
Solution 3 - PythoncaotView Answer on Stackoverflow