How do I remove the source (base) from my terminal?
I created some new aliases in my .bashrc file and did
source ~/.bashrc
Now, everytime I open my terminal it always comes with the (base)
How do I remove that?
That's the "base" environment from Anaconda or Miniconda. It means the Python environment from conda
is enabled by default.
There're two solutions.
-
Just disable the base environment, make sure your
conda >= 4.6
. Whenever you wanna use Python, enable an environment fromconda
manually with following command,# run this in an interactive shell # enable environment called "base", the default env from conda conda activate base # deactivate an environment conda deactivate
-
Enable the base environment, which is the default behavior of
conda
, but don't modify your prompt. Run the following command in an interactive shell once.conda config --set changeps1 false
If you'd prefer that conda's base environment not be activated on startup, you can always set the auto_activate_base
parameter to false:
conda config --set auto_activate_base false
The following code in the .bashrc file should initialize an anaconda environment. Just remove them.
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/Users/proshore/opt/anaconda3/bin/conda' 'shell.zsh' 'hook' 2$
if [ $? -eq 0 ]; then
eval "$__conda_setup"
else
if [ -f "/Users/proshore/opt/anaconda3/etc/profile.d/conda.sh" ]; then
. "/Users/proshore/opt/anaconda3/etc/profile.d/conda.sh"
else
export PATH="/Users/proshore/opt/anaconda3/bin:$PATH"
fi
fi
unset __conda_setup
# <<< conda initialize <<<