lluis lluis - 8 months ago 53
Git Question

git: can I accept both changes in a merge conflict without editing files?

I usually have merge conflicts on Rails locale files, for example:

<<<<<<< HEAD
label_company_offices: "Branches"
field_amounts_withheld: "Withheld amount"
>>>>>>> master

here I have to edit every locale file, can I avoid this?

there's any way to tell git "resolve conflict accepting both changes"?


this does the job for me:

ruby -pi -e "gsub(/^[=<>*]{7}.*\n/,'')" config/locales/*.yml