比如在.bashrc中写了一个:
export PATH=/Users/hczhang/bin:$PATH
但是启动一个新的terminal的时候整个path并没有生效,这是因为Mac OS terminal并不读取.bashrc, 而是读取.bash_profile, 所以为了简便起见,直接copy bashrc中的内容到bash_profile中。
就可以了。
当然你也可以每次都source ~/.bashrc
原文:http://blog.csdn.net/hongchangfirst/article/details/88883878
作者:hongchangfirst
hongchangfirst的主页:http://blog.csdn.net/hongchangfirst