Tutorial 3 overwrites the submission. 7. Merge--squash
To save time, this tutorial uses the existing history as a local database.
Download from here
We move to the STEPUP-TUTORIAL/TUTORIAL7 directory. The status of the local side history is shown in the following figure. Merges all commits of the Issue1 branch into a single commit and imports it into the master branch.
After switching to the master branch, specify the--squash option to perform the merge.
$ git checkout master
switched to branch ' master '
$ git merge--squash issue1
auto-merging sample.txt
CON Flict (content): merge conflict in Sample.txt
Squash commit – not updating HEAD
Automatic Merge failed; fix CONFL ICTs and then commits the result.
There seems to be a conflict. Please open sample.txt, modify the conflicting section, and then submit.
$ git add sample.txt
$ git commit
[master 0d744a7] Conflicts: sample.txt
1 files changed, 4 insertions (+) , 0 deletions (-)
All commits on the Issue1 branch are pooled and added to the master branch. Please use the log command to confirm the history.
From:http://backlogtool.com/git-guide/cn/stepup/stepup7_7.html