繁体   English   中英

bash_profile:没有这样的文件或目录

[英]bash_profile: No such file or directory

我得到提示:

-bash: source/Users/sean/.bash_profile: No such file or directory
-bash: /Users/sean/.bash_profile: line 3: syntax error near unexpected token `newline'
-bash: /Users/sean/.bash_profile: line 3: `PS1=\w >'
Seans-MacBook-Pro:~ sean$ source .bash_profile
-bash: source/Users/sean/.bash_profile: No such file or directory
-bash: .bash_profile: line 3: syntax error near unexpected token `newline'
-bash: .bash_profile: line 3: `PS1=\w >

当我打开.bash_profile时,它说的是

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source/Users/seanlanning/.bash_profile "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
PS1=\w >
PS1='\w >'

不知道我搞砸了什么,.bash_profile应该是什么样

在行中

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source/Users/seanlanning/.bash_profile "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*

您需要在source/Users...之间source一个空格/Users...

检查以确保您没有合并以下行:

export PATH=/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/sbin:/usr/sbin

[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function

什么操作系统

这条线

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source/Users/seanlanning/.bash_profile "$HOME/.rvm/scripts/rvm"

应该

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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