看起来你的shell没有正确配置使用conda activate
命令。这可能是因为你在安装Anaconda时没有选择将其添加到系统路径中。
解决这个问题的方法是运行conda init <SHELL_NAME>
命令来初始化你的shell。根据你当前使用的shell类型,可以尝试以下命令:
-
对于bash:
-
conda init bash
-
对于fish:
-
conda init fish
-
对于tcsh:
-
conda init tcsh
-
对于xonsh:
-
conda init xonsh
-
对于zsh:
-
conda init zsh
-
对于powershell:
-
conda init powershell
请注意,在运行完上述命令后,你可能需要关闭并重新打开你的shell才能使更改生效。