sudo gedit ~/.bashrc
在最后一行 添加
export PATH=/usr/local/arm/3.4.1/bin
我使用如上命令设置环境变量后,使用sudo dir等命令都不行了
Command 'sudo' is available in '/usr/bin/sudo'
The command could not be located because '/usr/bin' is not included in the PATH environment variable.
bash: sudo:找不到命令
Command 'dir' is available in '/bin/dir'
The command could not be located because '/bin' is not included in the PATH environment variable.
bash: dir:找不到命令
好像“export PATH=/usr/local/arm/3.4.1/bin”把原来的路径给覆盖掉了
请问如何加上“export PATH=/usr/local/arm/3.4.1/bin”而不影响sudo dir等功能呢
求助:ubuntu路径问题
-
- 帖子: 2
- 注册时间: 2008-11-11 10:20
- greatgarlic
- 帖子: 1794
- 注册时间: 2007-07-11 12:31
- 来自: neverland
- 联系:
-
- 帖子: 2
- 注册时间: 2008-11-11 10:20
Re: 求助:ubuntu路径问题
用这代码:
export PATH=$PATH:/usr/local/arm/3.4.1/bin
可以用了,非常感谢 greatgarlic
export PATH=$PATH:/usr/local/arm/3.4.1/bin
可以用了,非常感谢 greatgarlic