2013-11-20 53 views
0

我不明白爲什麼我的別名不工作,任何想法的人?我想用'pro'作爲別名 謝謝!^_ ^)爲什麼我會得到「-bash:'alias:command not found」,但它在那裏..?

這是我的bash文件的樣子:

export PATH="/usr/local/bin:$PATH" 

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


# Git branch in prompt. 
parse_git_branch() { 
    git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' 
} 
export PS1="\[email protected]\h \W\[\033[32m\]\$(parse_git_branch)\[\033[00m\] $ " 

#******ALIAS FOR TEALEAF_COURSE3********************** 

alias pro='cd /Users/yoniPacheko/Documents/ruby/RnR/third_course_0/projects ' 
+0

什麼「bash文件」是,你確定它是完全沒有修改? – trojanfoe

+0

你怎麼使用別名?在命令行或腳本中?上面提到的'bash文件'的路徑是什麼? – devnull

+0

當你在命令行上輸入別名時,該別名是否有效? – Evert

回答

0

好,我一直在尋找所有的時間的.bash_profile 但我已經zsh的作爲外殼,所以我看着錯誤的地方。

的合適位置是.zshrc,對於那些不運行一個bash殼,並希望使別名

但感謝年投入社區,我的圖片最後。

:)

相關問題