title: gitattributes not setting merge driver correctly
body: <p>I have the following directory structure:</p>
  
  <pre><code>project/
      .git/
          ...
      app/
          ...
      config/
          initializers/
              braintree.rb
          environments/
              production.rb
      .gitattributes
  </code></pre>
  
  <p>My project uses two main branches, master and staging, each tracking a different remote (production and staging heroku apps).</p>
  
  <p>The idea is that the staging branch moves forward with new features, they get pushed to and tested on the staging remote, then master is fast-forwarded to match staging and pushed to the production remote.</p>
  
  <p>Here's what I want to do: freely merge these two branches while keeping their versions of <code>braintree.rb</code> and <code>production.rb</code> separate.</p>
  
  <p>To accomplish this, here is what I put in <code>.gitattributes</code> (as per the ProGit book):</p>
  
  <pre><code>config/initializers/braintree.rb merge=ours
  config/environments/production.rb merge=ours
  </code></pre>
  
  <p>The file is present in both branches. </p>
  
  <p>The problem I'm encountering is that this doesn't seem to have any effect on anything. Whenever I merge between the two, the files get changed anyway and I have to go change them again.</p>
  
  <p>I have a feeling I'm missing something horribly obvious, but so far it's escaping me. I know that other answers here have involved creating custom merge drivers, but the ProGit book makes no mention of this process and seems to imply that the <code>ours</code> driver is built in (and I've seen it mentioned in the man pages, so I'm relatively sure it is). The only other thing I can think of is that I've somehow put <code>.gitattributes</code> in the wrong place or messed up its contents, but I can't find much information on that. I've tried moving it to the same directory as the files, but to no avail. </p>
  
  <p>In case it's of any help, I'm running git version 1.7.2 on OS X. Any help would be much appreciated. </p>