{"id":26840,"date":"2022-12-31T18:06:25","date_gmt":"2022-12-31T18:06:25","guid":{"rendered":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/"},"modified":"2022-12-31T18:06:25","modified_gmt":"2022-12-31T18:06:25","slug":"how-to-use-git-merge","status":"publish","type":"post","link":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/","title":{"rendered":"How to Use Git merge"},"content":{"rendered":"<p> <a href=\"https:\/\/go.fiverr.com\/visit\/?bta=1052423&nci=17043\" Target=\"_Top\"><img loading=\"lazy\" decoding=\"async\" border=\"0\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/fiverr.ck-cdn.com\/tn\/serve\/?cid=40081059\"  width=\"601\" height=\"201\"><\/a>\n<\/p>\n<div>\n<figure style=\"width: 1200px\" class=\"wp-caption alignnone\"><img loading=\"lazy\" decoding=\"async\" class=\"type:primaryImage  wp-image-853826 size-full\" data-pagespeed-no-defer=\"\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/two-paths-merge-2.png?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Two footpaths merging into one in a grassy park.\" width=\"1200\" height=\"675\" data-crediturl=\"https:\/\/www.shutterstock.com\/image-photo\/park-grass-two-footpaths-merged-into-1463313017\" data-credittext=\"Master Hands\/Shutterstock.com\"\/><figcaption class=\"wp-caption-text\"><span class=\"type:primaryImage imagecredit\"><a href=\"https:\/\/www.shutterstock.com\/image-photo\/park-grass-two-footpaths-merged-into-1463313017\">Master Hands\/Shutterstock.com<\/a><\/span><\/figcaption><\/figure>\n<p>To merge a development branch into the current branch, use &#8220;git merge dev-branch-name&#8221;. If you get conflict warnings about a merge, use &#8220;git merge &#8211;abort&#8221; to back out of it, or edit the affected files and then commit them.<\/p>\n<p>Git uses branches to isolate development streams, to prevent the stable release branch from becoming polluted. Bringing work in a branch into the main stream means merging branches. Here\u2019s how you do it.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><a name=\"autotoc_anchor_0\"\/>What Is a Merge in Git?<\/h2>\n<p>Git was designed to make branching simple and fast. In contrast to other version control systems, branching on Git is a trivial matter. On multi-developer projects especially, branching is one of Git\u2019s core organizational tools.<\/p>\n<p>Branches sandbox new development efforts so that code can be modified or added without affecting the code in other branches, especially the main or master branch. This usually contains the stable version of your code base.<\/p>\n<p>Isolating these changes from your stable code version makes perfect sense. But sooner or later the new code will be tested, reviewed, and rubber-stamped to be rolled into the master branch. At that point, you need to merge your branch into the master branch.<\/p>\n<p>Actually, branches can have sub-branches so you might be merging your branch into some other branch instead of the master branch. Just remember that merges always take one branch and merge it into a\u00a0<em>target<\/em>\u00a0branch, whatever that branch may be. If you want to merge your master branch into another branch, you can even do that too.<\/p>\n<p>Like most actions in Git, you perform merges in your local repository and push them to your remote repository.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><a name=\"autotoc_anchor_1\"\/>Preparing to Merge a Branch in Git<\/h2>\n<p>We\u2019ve got a small development project with a local Git repository and a remote Git repository. We created a branch called \u201cbugfix14\u201d from the \u201cmaster\u201d branch and worked on a solution to a bug.<\/p>\n<p>That work is completed, and we\u2019ve tested our code. It all works as expected. We want to roll those changes into the master branch so that our fix is part of the next release of the software.<\/p>\n<p>There\u2019s a little preparation to be done before we perform the merge. We need to make sure the target branch\u2014in this case the \u201cmaster\u201d branch\u2014and the branch we\u2019re going to merge into it are both up to date.<\/p>\n<p>To do this we\u2019ll use the <code>git status<\/code> command.<\/p>\n<pre>git status<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853691\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/1.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Using git status to see the state of a branch\" width=\"644\" height=\"150\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<ul>\n<li><strong>On branch bugfix14<\/strong>: This is our current branch.<\/li>\n<li><strong>Your branch is up to date with \u2018origin\/bugfix\u2019<\/strong>: The branch in our local repository has the same commit history as the branch in the remote repository. That means they\u2019re identical.<\/li>\n<li><strong>nothing to commit<\/strong>\u00a0There are no changes in the staging area that haven\u2019t been committed.<\/li>\n<li><strong>working tree clean<\/strong>: There are no unstaged changes in the working directory.<\/li>\n<\/ul>\n<p>All of those indicate that the branch is up to date, and we\u2019re clear to proceed. If any of these indicated that changes existed, we\u2019d need to stage them, commit them, and push them to the remote. If someone else had worked on these files, we may need to pull their changes from the remote repository.<\/p>\n<p>Checking out the branch we\u2019re going to merge into simplifies the merging process. It also allows us to verify it is up to date. Let\u2019s have a look at the master branch.<\/p>\n<pre>git checkout master<\/pre>\n<pre>git status<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853692\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/2.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Checking out the master branch and using git status to see its state\" width=\"644\" height=\"210\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>We get the same confirmations that the \u201cmaster\u201d branch is up to date.<\/p>\n<p><strong>RELATED:<\/strong> <a href=\"https:\/\/www.howtogeek.com\/devops\/how-to-choose-the-git-workflow-branching-model-thats-right-for-your-team\/\"><strong><em>How to Choose the Git Workflow &amp; Branching Model That&#8217;s Right for Your Team<\/em><\/strong><\/a><\/p>\n<h2 role=\"heading\" aria-level=\"2\"><a name=\"autotoc_anchor_2\"\/>Performing a Merge<\/h2>\n<p>Before we merge, our commits look like this.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853694\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/before-local-merge.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"The commit history before the merge of a branch\" width=\"640\" height=\"325\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>The \u201cbugfix14\u201d branch was branched from the \u201cmaster\u201d branch. There has been a commit to the \u201cmaster\u201d branch after the \u201cbugfix14\u201d branch was created. There have been a couple of commits to the \u201cbugfix14\u201d branch.<\/p>\n<p>We\u2019ve made sure our two branches are up to date, and we\u2019ve checked out the \u201cmaster\u201d branch. We can issue the command to merge the \u201cbugfix14\u201d branch into the \u201cmaster\u201d branch.<\/p>\n<pre>git merge bugfix14<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853695\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/3.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"merging a branch with the git merge command\" width=\"644\" height=\"150\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>The merge takes place. The \u201cbugfix14\u201d branch still exists, but now the changes that were made in that branch have been merged into the \u201cmaster\u201d branch.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853700\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/after-local-merge.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"The commit history after the merge of a branch\" width=\"640\" height=\"320\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>In this instance the merge command performs a <em>three-way merge<\/em>. There are only two branches, but there are three commits involved. They are the head of either branch, and a third commit that represents the merge action itself.<\/p>\n<p>To update our remote repository, we can use the <em>git push<\/em> command.<\/p>\n<pre>git push<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853698\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/4.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Pushing changes to a remote repository\" width=\"644\" height=\"210\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Some people prefer to delete side branches once they\u2019ve merged them. Others take care to preserve them as a record of the true development history of the project.<\/p>\n<p>If you want to delete the branch, you can do so using the <code>git branch<\/code> command with the <code>-d<\/code> (delete) option.<\/p>\n<pre>git branch -d bugfix14<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853702\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/5.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Deleting a branch in the local repository \" width=\"644\" height=\"95\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>To <a href=\"https:\/\/www.howtogeek.com\/devops\/how-to-delete-git-branches-on-local-and-remote-repositories\/\">delete the branch<\/a> in the remote repository use this command:<\/p>\n<pre>git push origin --delete bugfix14<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853703\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/6.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Deleting a branch in the remote repository \" width=\"644\" height=\"130\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>You\u2019ll have a linear commit history, but it won\u2019t be the true history.<\/p>\n<p><strong>RELATED:<\/strong> <a href=\"https:\/\/www.howtogeek.com\/devops\/how-to-delete-git-branches-on-local-and-remote-repositories\/\"><strong><em>How to Delete Git Branches On Local and Remote Repositories<\/em><\/strong><\/a><\/p>\n<h2 role=\"heading\" aria-level=\"2\"><a name=\"autotoc_anchor_3\"\/>Performing a Fast-Forward Merge in Git<\/h2>\n<p>If you haven\u2019t made any commits to the \u201cmaster\u201d branch, your history will look like this. It will also look this if you\u2019ve <a href=\"https:\/\/www.howtogeek.com\/849210\/git-rebase\/\">rebased<\/a> your development branch so that it\u2019s attached to the end of the \u201cmaster\u201d branch.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853705\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/before-fast-forward-merge.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"The commit history before a fast-forward merge\" width=\"640\" height=\"326\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Because there are no commits in the \u201cmaster\u201d branch, to merge the \u201cbugfix15\u201d branch, all Git has to do is point the \u201cmaster\u201d head pointer to the last commit of the \u201cbugfix15\u201d branch.<\/p>\n<p>We can use the usual <code>git merge<\/code> command:<\/p>\n<pre>git merge bugfix15<\/pre>\n<p>That gives us this result.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853706\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/after-fast-forward-merge.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"One way to view the result of a fast-forward merge\" width=\"640\" height=\"325\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Which is the same as this:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853707\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/after-fast-forward-merge2.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Another way to view the result of a fast-forward merge\" width=\"640\" height=\"250\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Which is just the same as this:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853709\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/after-fast-forward-merge3.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Yet another way to view the result of a fast-forward merge\" width=\"639\" height=\"250\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Git will perform a fast-forward merge <em>whenever it can<\/em>. If commits to the \u201cmaster\u201d branch mean a fast-forward merge isn\u2019t possible, Git will use a <em>three-way merge<\/em>.<\/p>\n<p>You can\u2019t\u00a0<em>force<\/em>\u00a0a fast-forward merge\u2014it might not possible, after all\u2014but you can declare it\u2019s going to be fast-forward merge or nothing. There is an option that instructs Git to use a fast-forward merge if it can, but not to do a three-way merge if it can\u2019t. The option is <code>--ff-only<\/code> (fast-forward merge only).<\/p>\n<p>This merges the \u201cbugfix15\u201d branch into the \u201cmaster\u201d branch, but only if a fast-forward merge is possible.<\/p>\n<pre>git merge --ff-only bugfix15<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853712\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/7.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Using the --ff-only option to prevent a three-way merge from being used if a fast-forward merge is not possible\" width=\"644\" height=\"170\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Git will complain and exit if it isn\u2019t possible.<\/p>\n<pre>git merge --ff-only bugfix16<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853713\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/8.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Git not performing any merge because a fast-forward merge is not possible and the --ff-only option has been used\" width=\"644\" height=\"95\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>In this case, there have been commits to the \u201cmaster\u201d branch, so a fast-forward merge isn\u2019t possible.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><a name=\"autotoc_anchor_4\"\/>How to Resolve Merge Conflicts in Git<\/h2>\n<p>If the same portions of the same file have been changed in the both branches, the branches cannot be merged. Human interaction is required to resolve the conflicting edits.<\/p>\n<p>Here, we\u2019ve got made changes to a file called \u201crot.c\u201d in a branch called called \u201cbugfix17\u201d that we want to merge to the \u201cmaster\u201d branch. But \u201crot.c\u201d has been changed in the \u201cmaster\u201d branch too.<\/p>\n<pre>git merge bugfix17<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853715\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/9.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Get reporting conflicts and halting a merge\" width=\"644\" height=\"130\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>When we try to merge it, we get a warning that there are conflicts. Git lists the conflicting files, and tells us the merge failed. We could back out completely using the <code>--abort<\/code> option:<\/p>\n<pre>git merge --abort<\/pre>\n<p>But resolving merges isn\u2019t as scary as it sounds. Git has done some work to help us. If we edit one of the conflicting files\u2014in our case, we only have one\u2014we\u2019ll find the conflicting code sections highlighted for us.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853717\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/10.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"How git identifies conflicts within a file\" width=\"625\" height=\"235\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Each conflict is bounded by seven less-than characters \u201c<code>&lt;&lt;&lt;&lt;&lt;&lt;&lt;<\/code>\u201d and seven greater-than characters \u201c<code>&gt;&gt;&gt;&gt;&gt;&gt;&gt;<\/code>\u201c, with seven equals signs \u201c<code>=======<\/code>\u201d between them.<\/p>\n<ul>\n<li>The code above the equals signs is from the branch you\u2019re merging <em>into<\/em>.<\/li>\n<li>The code below the equals sign is the code from the branch you\u2019re trying to <em>merge<\/em>.<\/li>\n<\/ul>\n<p>You can easily search for one of the sets of seven characters and move from conflict to conflict through your file. For each conflict, you need to choose which set of edits you\u2019re going to keep. You must edit out the code you\u2019re rejecting, and the seven-character lines that Git has added.<\/p>\n<p>We\u2019re going to keep the code from the \u201cbugfix17\u201d branch. After editing, our file looks like this.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853719\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/11.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"The edited text, resolving the merge conflict\" width=\"625\" height=\"225\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>We can now carry on with the merge. But note, we use the <code>commit<\/code> command to do so, not the <code>merge<\/code> command.<\/p>\n<p>We commit the change by staging the file and committing it as usual. We\u2019ll check the status before we make the final commit.<\/p>\n<pre>git add rot.c<\/pre>\n<pre>git status<\/pre>\n<pre>git commit -m \"Merged bugfix17\"<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-853720\" data-pagespeed-lazy-src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/12\/12.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Using the commit command to complete a merge after resolving conflicts\" width=\"644\" height=\"315\" src=\"https:\/\/mailinvest.blog\/wp-content\/themes\/breek\/assets\/images\/transparent.gif\" data-lazy=\"true\" data-src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>The merge is complete. We can now push this to our remote repository.<\/p>\n<p><strong>RELATED:<\/strong> <a href=\"https:\/\/www.howtogeek.com\/devops\/how-to-fix-edit-or-undo-git-commits-changing-git-history\/\"><strong><em>How to Fix, Edit, or Undo Git Commits (Changing Git History)<\/em><\/strong><\/a><\/p>\n<h2 role=\"heading\" aria-level=\"2\"><a name=\"autotoc_anchor_5\"\/>Everything Merges Eventually<\/h2>\n<p>All branches need to be merged, eventually, so that the changes in them don\u2019t become orphaned and forgotten about.<\/p>\n<p>Merging branches is easy, but dealing with conflicts can get complicated in busy, larger teams. Resolving conflicts may require input from each developer just to explain what their code does and why they made their changes. You need to understand that, before you can make an informed decision about which edits to keep.<\/p>\n<p>Sadly, Git can\u2019t help with that.<\/p>\n<p><strong>RELATED:<\/strong> <a href=\"https:\/\/www.howtogeek.com\/devops\/should-you-use-a-gui-git-client\/\"><strong><em>Should You Use a GUI Git Client?<\/em><\/strong><\/a><\/p>\n<\/div>\n<iframe data-lazy=\"true\" data-src=\"https:\/\/www.fiverr.com\/gig_widgets?id=U2FsdGVkX18x7XQvttUTrv1oEqmGNGTgvvCUiUoJ\/AP4z\/UyMz8lXGOLpu15jIMxBbTR0gmD5uBoFvhC4KWeALQRp3h\/X\/AwcVD0K8Wj9H\/ZzYKzcCNHosB9oS4SCJJFWiN85P9ICAc4OgCoE\/wHKIY7CDkf2\/DQ1vqGvk4smVe5cRDEmrLPCWi4FC8p40VUhSmWQ5udCm0zoJtorgWv3vbDQw0kKYkwn39ozAnQXDe+YvWMxkLFWA+O3TFwkJvdkIK+\/AUSnRssPKt5WHY0FhNOxnSPcLslEL4G4\/RfP95ve99U+kRnDy3X+KtzdQLY+u935ghON\/o3UE4IMv9oN6JX9RnxzL\/LRcOgnHigxStSGPKsZYtnz8RWNVT\/rOLAibqiWJadC5MYHRbekF3eg6FOGrQGkXYbsn0+a5aovnlLCbLwIqY9fcS17UX8J235iQ6cdmHNbrPeS84CMm34RA==&affiliate_id=1052423&strip_google_tagmanager=true\" loading=\"lazy\" data-with-title=\"true\" class=\"fiverr_nga_frame\" frameborder=\"0\" height=\"350\" width=\"100%\" referrerpolicy=\"no-referrer-when-downgrade\" data-mode=\"random_gigs\" onload=\" var frame = this; var script = document.createElement('script'); script.addEventListener('load', function() { window.FW_SDK.register(frame); }); script.setAttribute('src', 'https:\/\/www.fiverr.com\/gig_widgets\/sdk'); document.body.appendChild(script); \" ><\/iframe>\n<br \/><a href=\"https:\/\/www.howtogeek.com\/853521\/git-merge\/\">Source link <\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Master Hands\/Shutterstock.com To merge a development branch into the current branch, use &#8220;git merge dev-branch-name&#8221;. If you get conflict warnings about a merge, use &#8220;git&#8230;<\/p>\n","protected":false},"author":1,"featured_media":26841,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-26840","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tech-universe"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How to Use Git merge - mailinvest.blog<\/title>\n<meta name=\"description\" content=\"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis.mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what&#039;s new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Use Git merge - mailinvest.blog\" \/>\n<meta property=\"og:description\" content=\"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis.mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what&#039;s new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/\" \/>\n<meta property=\"og:site_name\" content=\"mailinvest.blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/freelanceracademic\/\" \/>\n<meta property=\"article:published_time\" content=\"2022-12-31T18:06:25+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/12\/two-paths-merge-2-1024x575.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"575\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"admin@mailinvest.blog\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin@mailinvest.blog\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/\"},\"author\":{\"name\":\"admin@mailinvest.blog\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#\\\/schema\\\/person\\\/012701c4c204d4e4ebd34f926cfd31a4\"},\"headline\":\"How to Use Git merge\",\"datePublished\":\"2022-12-31T18:06:25+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/\"},\"wordCount\":1509,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/mailinvest.blog\\\/wp-content\\\/uploads\\\/2022\\\/12\\\/two-paths-merge-2.png\",\"articleSection\":[\"Tech Universe\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/\",\"url\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/\",\"name\":\"How to Use Git merge - mailinvest.blog\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/mailinvest.blog\\\/wp-content\\\/uploads\\\/2022\\\/12\\\/two-paths-merge-2.png\",\"datePublished\":\"2022-12-31T18:06:25+00:00\",\"description\":\"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis.mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what's new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#primaryimage\",\"url\":\"https:\\\/\\\/mailinvest.blog\\\/wp-content\\\/uploads\\\/2022\\\/12\\\/two-paths-merge-2.png\",\"contentUrl\":\"https:\\\/\\\/mailinvest.blog\\\/wp-content\\\/uploads\\\/2022\\\/12\\\/two-paths-merge-2.png\",\"width\":2392,\"height\":1342},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/2022\\\/12\\\/31\\\/how-to-use-git-merge\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/mailinvest.blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Use Git merge\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#website\",\"url\":\"https:\\\/\\\/mailinvest.blog\\\/\",\"name\":\"mailinvest.blog\",\"description\":\"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis. mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what&#039;s new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.\",\"publisher\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/mailinvest.blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#organization\",\"name\":\"mailinvest\",\"url\":\"https:\\\/\\\/mailinvest.blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/mailinvest.blog\\\/wp-content\\\/uploads\\\/2022\\\/01\\\/default.png\",\"contentUrl\":\"https:\\\/\\\/mailinvest.blog\\\/wp-content\\\/uploads\\\/2022\\\/01\\\/default.png\",\"width\":1000,\"height\":1000,\"caption\":\"mailinvest\"},\"image\":{\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/freelanceracademic\\\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/mailinvest.blog\\\/#\\\/schema\\\/person\\\/012701c4c204d4e4ebd34f926cfd31a4\",\"name\":\"admin@mailinvest.blog\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/98ed217bd0f3d6a6dcae2d9b0c76e305b049a07275e315e1407e19ec8b08e139?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/98ed217bd0f3d6a6dcae2d9b0c76e305b049a07275e315e1407e19ec8b08e139?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/98ed217bd0f3d6a6dcae2d9b0c76e305b049a07275e315e1407e19ec8b08e139?s=96&d=mm&r=g\",\"caption\":\"admin@mailinvest.blog\"},\"sameAs\":[\"https:\\\/\\\/mailinvest.blog\",\"admin@mailinvest.blog\"],\"url\":\"https:\\\/\\\/mailinvest.blog\\\/index.php\\\/author\\\/adminmailinvest-blog\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Use Git merge - mailinvest.blog","description":"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis.mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what's new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/","og_locale":"en_US","og_type":"article","og_title":"How to Use Git merge - mailinvest.blog","og_description":"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis.mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what's new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.","og_url":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/","og_site_name":"mailinvest.blog","article_publisher":"https:\/\/www.facebook.com\/freelanceracademic\/","article_published_time":"2022-12-31T18:06:25+00:00","og_image":[{"width":1024,"height":575,"url":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/12\/two-paths-merge-2-1024x575.png","type":"image\/png"}],"author":"admin@mailinvest.blog","twitter_card":"summary_large_image","twitter_misc":{"Written by":"admin@mailinvest.blog","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#article","isPartOf":{"@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/"},"author":{"name":"admin@mailinvest.blog","@id":"https:\/\/mailinvest.blog\/#\/schema\/person\/012701c4c204d4e4ebd34f926cfd31a4"},"headline":"How to Use Git merge","datePublished":"2022-12-31T18:06:25+00:00","mainEntityOfPage":{"@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/"},"wordCount":1509,"commentCount":0,"publisher":{"@id":"https:\/\/mailinvest.blog\/#organization"},"image":{"@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#primaryimage"},"thumbnailUrl":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/12\/two-paths-merge-2.png","articleSection":["Tech Universe"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/","url":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/","name":"How to Use Git merge - mailinvest.blog","isPartOf":{"@id":"https:\/\/mailinvest.blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#primaryimage"},"image":{"@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#primaryimage"},"thumbnailUrl":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/12\/two-paths-merge-2.png","datePublished":"2022-12-31T18:06:25+00:00","description":"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis.mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what's new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.","breadcrumb":{"@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#primaryimage","url":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/12\/two-paths-merge-2.png","contentUrl":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/12\/two-paths-merge-2.png","width":2392,"height":1342},{"@type":"BreadcrumbList","@id":"https:\/\/mailinvest.blog\/index.php\/2022\/12\/31\/how-to-use-git-merge\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/mailinvest.blog\/"},{"@type":"ListItem","position":2,"name":"How to Use Git merge"}]},{"@type":"WebSite","@id":"https:\/\/mailinvest.blog\/#website","url":"https:\/\/mailinvest.blog\/","name":"mailinvest.blog","description":"Technology is forever changing, and there are always new pieces of technology to replace obsolete ones. Tons of people enjoy reading tech blogs on a daily basis. mailinvest.blog tracks all the latest consumer technology breakthroughs and shows you what&#039;s new, what matters and how technology can enrich your life. mailinvest.blog also provides the information, tools, and advice that helps when deciding what to buy.","publisher":{"@id":"https:\/\/mailinvest.blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/mailinvest.blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/mailinvest.blog\/#organization","name":"mailinvest","url":"https:\/\/mailinvest.blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/mailinvest.blog\/#\/schema\/logo\/image\/","url":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/01\/default.png","contentUrl":"https:\/\/mailinvest.blog\/wp-content\/uploads\/2022\/01\/default.png","width":1000,"height":1000,"caption":"mailinvest"},"image":{"@id":"https:\/\/mailinvest.blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/freelanceracademic\/"]},{"@type":"Person","@id":"https:\/\/mailinvest.blog\/#\/schema\/person\/012701c4c204d4e4ebd34f926cfd31a4","name":"admin@mailinvest.blog","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/98ed217bd0f3d6a6dcae2d9b0c76e305b049a07275e315e1407e19ec8b08e139?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/98ed217bd0f3d6a6dcae2d9b0c76e305b049a07275e315e1407e19ec8b08e139?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/98ed217bd0f3d6a6dcae2d9b0c76e305b049a07275e315e1407e19ec8b08e139?s=96&d=mm&r=g","caption":"admin@mailinvest.blog"},"sameAs":["https:\/\/mailinvest.blog","admin@mailinvest.blog"],"url":"https:\/\/mailinvest.blog\/index.php\/author\/adminmailinvest-blog\/"}]}},"_links":{"self":[{"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/posts\/26840","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/comments?post=26840"}],"version-history":[{"count":0,"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/posts\/26840\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/media\/26841"}],"wp:attachment":[{"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/media?parent=26840"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/categories?post=26840"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mailinvest.blog\/index.php\/wp-json\/wp\/v2\/tags?post=26840"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}