问题描述
在用conda激活环境时输入conda activate XXX 报错
错误提示
CommandNotFoundError: Your shell has not been properly configured to use ‘conda activate’.
To initialize your shell, run
$ conda init <SHELL_NAME>
Currently supported shells are:
- bash
- fish
- tcsh
- xonsh
- zsh
- powershell
See ‘conda init --help’ for more information and options.
IMPORTANT: You may need to close and restart your shell after running ‘conda init’.
错误提示 译
CommandNotFoundError: 您的 shell 未正确配置为使用 “conda activate”。
要初始化 shell,请运行
$ conda init <SHELL_NAME>
目前支持的 shell 有
- bash
- fish
- tcsh
- xonsh
- zsh
- powerhell
请参阅 “conda init --help” 获取更多信息和选项。
重要:运行 "conda init "后,可能需要关闭并重新启动 shell。
解决方法
$ bash