Skip to contentSkip to conversation

excluding files from a merge

DISCUSSION Daniel Jacobs 3 participants 4 messages Jun 15, 2016

lore
Share & tools
lore
#0 lore raw

Our project has two main branches set up, one called 'development, and another called 'production'.

Each branch has a file in it called database.yml, (this is a rails project)...
The development branch and the
production branch are supposed to have different versions of this file. (and not only this file, but other
config sorts of files as well, but this is a good example).

At the same time, when development is ready for deployment, we will do git checkout production
git merge development

I would like it if every file was merged, except for files that were explictly excluded from a merge between these two branches. Is there a good way to do this?

-Daniel

#1 lore raw
Quoted 3 lines · Daniel Jacobs

I would like it if every file was merged, except for files that were explictly excluded from a merge between these two branches.  Is there a good way to do this?

Please see http://thread.gmane.org/gmane.comp.version-control.git/110488
(Is there a way to exclude user-specified files or directories from participating in merges?)

I believe it is the same use case, and Junio provided a very detailed reply.

HTH,

j.

#2 lore raw

Quoting Jay Soffian <[email protected]>:

Quoted 10 lines · Daniel Jacobs
Quoted 3 lines

I would like it if every file was merged, except for files that were explictly excluded from a merge between these two branches.  Is there a good way to do this?

Please see http://thread.gmane.org/gmane.comp.version-control.git/110488
(Is there a way to exclude user-specified files or directories from participating in merges?)

I believe it is the same use case, and Junio provided a very detailed reply.

Would it help to have the final summary by Sitaram Chamarty

    http://article.gmane.org/gmane.comp.version-control.git/110697

somewhere under Documentation/howto?

Signature · 2 lines
Nanako Shiraishi
http://ivory.ap.teacup.com/nanako3/