title: Git keeps removing group write permissions
body: <p>I have a git repository that I am sharing with several developers. We do regular git pulls and pushes with it. Unfortunately, every time I do a git pull the changed files lose the group write permission. How do I stop git from doing this?</p>
  
  <p>I am running this on Ubuntu 12.04 LTS.</p>
  
  <p>The config on the shared repo looks like this:</p>
  
  <pre><code>[core]
          repositoryformatversion = 0
          filemode = true
          bare = true
          sharedRepository = group
  </code></pre>
  
  <p>I also ran the following commands on it in an attempt to fix it</p>
  
  <pre><code>find repo.git -type d -exec chmod g+rws {} +
  sudo chmod -R g+rw repo.git/objects
  </code></pre>
  
  <p>No matter what I end up with folders with 755 and files with 644 when I want 775 and 664 respectively.</p>