There are a bunch of files in my project that are sometimes modified but always shared among many different branches. Examples include build scripts, batch files that include p
For simple systems, I'll create base versions of these files that are in version control that are then adapted for each instance, the files for which are in .gitignore.
If I'm using a more sophisticated tool chain, I'll create source XML files that describe the base pieces, XML files that describe the specific instance variations then run an XSLT using a profile or command line property to generate the locally appropriate versions as part of the build configuration/script depending on your poison. This doesn't have to be XML/XSL, I just deal in XML a lot, you could use any kind of munging system that works with your build environment, say text files with perl scripts or just sed/awk.