Git 分支除錯


1
2
3
4
5
6
7
git branch bug_fix # 建立分支並命名為 bug_fix
git checkout bug_fix # 切換到 bug_fix 分支
git checkout master # 切換回 repository
git merge bug_fix # 把 bug_fix 這個分支和現在的分支合併
git push origin bug_fix:refs/heads/bug_fix # 把 bug_fix 這個分支推送到遠方的 repository 上面的 bug_fix 分支上

git push origin 本機:遠方

參考:

  1. http://gitbook.liuhui998.com/7_8.html
  2. http://billy3321.blogspot.com/2009/02/github-howto.html