1.同步脚本
cd /data/wwwroot/bc
/usr/bin/git reset --hard/usr/bin/git pull
rm -rf ___cache/
2.git clone 远程分支
能看到远程的所有的分支,如remotes/origin/python_mail.skin e Y' X9 ~, f1 |
可以使用checkout命令来把远程分支取到本地,并自动建立tracking
- $ git checkout -b python_mail.skin origin/python_mail.skin) X& X: I3 Q; ?9 j9 T5 @; J/ M
- Branch python_mail.skin set up to track remote branch python_mail.skin from origin.; i/ B! ^3 J# u6 a( }. I$ M- i
- Switched to a new branch 'python_mail.skin
参考文章
http://blog.csdn.net/xqs83/article/details/7382074