We need a systematic way of ignoring a specific config file for the branches we maintain on git.
i.e. we have a config.xml
file with database, environment, and other info across 'develop' and 'master' branches that we'd like to keep out of the outcomes of 'git merge'.
We followed the SCM book instructions for merge strategies, but git still seem to be merging config.xml
when we do branch merges:
http://git-scm.com/book/en/v2/Customizing-Git-Git-Attributes#Merge-Strategies
I've also had a look at this SO post which require conscious programmer effort to selectively ignore the config.xml
file - seem to be prune to error:
Different configs in each git branch
There's also this SO post which explains the different git merge strategies, other than ours
, none of the others seem to suit our purpose:
When would you use the different git merge strategies?
I'm curious what methods you guys use to control the changes to config files that stays pretty consistent in each branch without having 'git merge
' mess things up?