Git Note - Branch

Craftor發表於2014-06-27

1. add a new branch

cd workspace
git branch user1/newbranch1
git checkout user1/newbranch1

or

git checkout -b user2/newbranch2

2. when user1/newbranch1 development finished, merge it into master branch.

git checkout master
git merge user1/newbranch1

delete branch user1/newbranch1

git branch -d user1/newbranch1

相關文章