2

I am working remotely on my university's cluster. I have created two new conda environments: lammps-old and lammps-new. When I activate any environmet of them the username and current directory indicator disappear. Now they also disappeared in the base environment.

I have tried cutomizing the PS1 in the ~/.bashrc and ~/.bash_profile using:

export PS1="($CONDA_DEFAULT_ENV) [$LOGNAME@$HOSTNAME($SLURM_STEP_NODELIST) $PWD]$ "

But this only solves the problem for the base environment.

I would appreciate any help.

merv
  • 67,214
  • 13
  • 180
  • 245
Mohamed
  • 181
  • 1
  • 2
  • 10
  • Does this answer your question? [Changing conda PS1 prompt](https://stackoverflow.com/questions/73883992/changing-conda-ps1-prompt) – merv Dec 06 '22 at 14:37

2 Answers2

3

You can set changeps1 to False by running the following command in the terminal:

conda config --set changeps1 False

or manually update .condarc.

https://conda.io/projects/conda/en/latest/user-guide/configuration/use-condarc.html#change-command-prompt-changeps1

runwuf
  • 1,701
  • 1
  • 8
  • 15
3

Run this command and try

conda init bash
Dixon MD
  • 168
  • 2
  • 11