1. 程式人生 > >Git中修復bug

Git中修復bug

問題描述:提交的遠端分支中有一個小bug需要修復;

首先在本地拉取指定分支的程式碼:

git checkout -b test origin/遠端分支
git pull

再從test分支中切一個分支:

git checkout -b issue-01

修改相應的bug,並提交到暫存區:

git add 
git commit -m ""

然後切換到test分支,並merge分支issue-01:

git merge issue-01

然後提交分支test到遠端分支