【发布时间】:2016-03-09 05:56:58
【问题描述】:
我刚刚使用 conda create --name py35 python=3.5 anaconda 将 python 3.5 添加到 anaconda 的环境中
我将anaconda的bin、envs和py35的路径依次添加到PATH变量中,没有任何效果。
我总是遇到同样的错误:
>>> source activate py35
activate: No such file or directory.
>>> activate py35
Error: activate must be sourced. Run 'source activate envname'
instead of 'activate envname'.
Usage: source activate ENV
adds the 'bin' directory of the environment ENV to the front of PATH.
ENV may either refer to just the name of the environment, or the full
prefix path.
>>> cd anaconda/bin
>>> ls | grep activate
activate
activate-global-python-argcomplete
deactivate
>>> source activate py35
Illegal variable name.
我很困惑
编辑:echo $PATH 给予
/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda:/local/home/sread/Apps/anaconda/bin:/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda/envs:/local/home/sread/Apps/anaconda/bin:/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda/envs/py3k:/local/home/sread/Apps/anaconda/bin:/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda/envs:/local/home/sread/Apps/anaconda/bin:/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda/bin:/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda/bin:/star/java/jre/bin:/star/java/bin:/soft/cuter:/soft/cuter/CUTEr.large.pc.lnx.gfo/bin:/soft/sifdec:/soft/sifdec/SifDec.large.pc.lnx.gfo/bin:/local/home/sread/Apps/texlive/2015/bin/x86_64-linux:/local/home/sread/Apps/anaconda/bin:/usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/soft/bin:/soft/AstroMatic/bin:/star/bin/startcl:/star/bin:/star/starjava/bin
【问题讨论】:
-
echo $PATH的输出是什么?
标签: python linux python-3.x path anaconda