9

I have been using iterm2 for a couple years now and its great. Lately, however, my prompt has changed in an odd way and I can't tell what it is telling me. Originally, my prompt looked like this:

<username>@<hostname>:<current_dir>$

Now, the prompt looks like this:

(base) $<username>@<hostname>:<current_dir>$

I'm running Mojave and checked my .bashrc file – everything looks normal there.

Does anyone have an idea as to what "(base)" is? What is it telling me? And how can I get rid of it?

bottlecap
  • 455
  • 1
  • 5
  • 9

3 Answers3

19

I did some further analysis of my .bash_profile file and I was able to isolate the (base) to a section that adds the Python Anaconda distribution into my path. After some further Googling, it turns out I had inadvertently created a virtual environment for my Anaconda work. This wasn't necessary, so I removed the environment by typing source deactivate. My terminal session now no longer shows (base).

Thanks to Blockchain Business for the info on how to disable a virtual environment.

bottlecap
  • 455
  • 1
  • 5
  • 9
  • 4
    This happened to me today after I did a python tutorial and installed Anaconda, so I tried this and now you have to type in `conda deactivate`. I think I probably want to disable this all together, but for now, this works. – thehme Nov 09 '19 at 02:08
  • If you want to deactivate it for all new shells, https://stackoverflow.com/a/54560785/1319850 – reergymerej Sep 23 '21 at 13:17
14

conda config --set auto_activate_base false

YangzeXie
  • 141
  • 1
  • 2
  • 2
    Please add some explanation to your answer by editing it, such that others can learn from it – Nico Haase Mar 05 '20 at 12:56
  • here is a bit explaination https://stackoverflow.com/questions/54429210/how-do-i-prevent-conda-from-activating-the-base-environment-by-default – Asim Zaidi Nov 26 '20 at 15:21
2

It is when you have added conda library to your path. Run conda deactivate should get rid of the (base) text from your terminal

webgoesviral
  • 345
  • 2
  • 8