Skip to content
Minsing Log
Go back

English Edition

How to Merge

Programming & CS

What is merge?

It is the process of merging the contents of a newly created branch into the main branch. By making changes in the newly created branch, the main branch

Refer to the merge details

How to merge the GitHub master branch into the main branch

Method

  1. Switch branches (when switching by force, checkout -f main)
# git checkout main
  1. Merge branches (move to the target branch using checkout, then specify the branch to merge—the example below shows merging the test branch into the main branch)
# git merge test

In case of a conflict during merge

Cause

1. Edit manually

2. Cancel the merge operation


Tip)

-> After merging, the changes are reflected only locally, so you need to push the contents of the main branch separately for them to be reflected on GitHub.

-> Whenever possible, merge on GitHub!


How to test

Try testing it using the method in this link

Image URL: http://luckcrow.egloos.com/2631202

Follow the journey

Get new posts by email.

Short, honest notes on building, startups, learning, failures, and retrospectives, for readers who follow the journey rather than pass through from search.

The newsletter is coming soon. Until then, follow via RSS or email me to get notified.


Share this post:

Comments

Sign in with GitHub to leave a comment.


Previous Post
When git add doesn't work even though the file is perfectly fine
Next Post
About add/push-commit/pull-fetch