A Better Approach to Merging Files in Git

A Better Approach to Merging Files in Git

Brice McIver Articles, Development Technologies & Tools, Git Leave a Comment

Git has many features, but itโ€™s likely that you only use a small subset on a daily basis. While git tends to handle things intelligently most of the time, there are situations when doing the most obvious thing doesnโ€™t give git enough information to make informed choices.

In this post, weโ€™ll examine one such scenario – merging files. Through trial and error, Iโ€™ll show you the normal approach people take, some of the issues that occur with that approach, and a completely different approach that preserves some data lost in the first approach.