简体   繁体   中英

Warning on git bash start "bash: C:/Users/RS3/Anaconda3/etc/profile.d/conda.sh: No such file or directory"

Whenever I open git bash I get the following warning: bash: C:/Users/RS3/Anaconda3/etc/profile.d/conda.sh: No such file or directory

The problem is that I uninstalled Anaconda, because I installed independent python, which resulted in giving that error.

How to remove this Warning.

警告

Check the content of ~/.bashrc (which was mentioned here )

Maybe that (or ~/.profile , mentioned here ) includes a command for that old uni uninstalled program.

Remove those lines, and try to open again a git bash session.

To remove that warning, simply erase the file path string in the .bashrc file using nano command. Here's how:

Steps to remove that warning:

  1. Open Git Bash and check .bashrc location by typing ~/.bashrc into git bash.
  2. Navigate to folder where .bashrc file is located.
  3. Type nano .bashrc
  4. Erase the string that says C:/Users/RS3/Anaconda3/etc/profile.d/conda.sh
  5. Press ctrl+O to save .bashrc file and then ctrl+X to exit.

When you reopen git bash nothing should appear because .bashrc doesn't have that path in it anymore. Also, if conda commands were working before it will still continue to work after erasing this.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM