我搜索了一些答案,但是并没有成功地修改我的内容。
操作系统:Mac OS X
我的.bashrc内容:
# Before other PATHs...
PATH=${PATH}:/usr/local/share/python
alias la='ls -la'
function find_cpp_filepath_with_string { find $1 -name "*.cpp" -type f -exec grep -l $2 {} \;}
#export -f find_cpp_filepath_with_string
else
echo "WARNING: Can't find virtualenvwrapper.sh"
fi
这句话有些棘手,具体是以下内容。
function find_cpp_filepath_with_string { find $1 -name "*.cpp" -type f -exec grep -l $2 {} \;}
尝试执行 source ~/.bashrc 后的结果是:
line 21: syntax error: unexpected end of file