title: How to create a Git attributes file
body: <p>I would like to add an attributes file to my Git repository as described <a href="https://git-scm.com/docs/gitattributes" rel="noreferrer">here</a>. It indicates that I should include <code>.gitattributes</code> in the root folder of my repository.</p>
  
  <ul>
  <li><p>Is <code>.gitattributes</code> simply a file or is it a folder ? How do I create this file/folder ? </p>
  
  <p><em>Windows raises the following errors :</em></p>
  
  <blockquote>
    <p><strong>"Can't create a file without a filename"</strong></p>
  </blockquote>
  
  <p></p>
  
  <blockquote>
    <p><strong>"You must type a filename"</strong></p>
  </blockquote></li>
  <li><p>Where should one add the file ? Under the repository root, <code>X:\PATH\TO\Repository\</code>, or the Git folder, <code>X:\PATH\TO\Repository\.git\</code> ?</p></li>
  <li><p>Will the attributes be enforced for other contributors cloning/forking my repository ?</p>
  
  <p><em>e.g. If I pushed to GitHub or GitLab and some other party pulled down a copy would the attributes I added be enforced upon their machine as well ?</em></p></li>
  </ul>
  
  <p><strong>Related :</strong> <a href="https://stackoverflow.com/q/48207907/958580">Git Ignore</a></p>
  
  <p><strong>Note :</strong> I'm using <a href="http://en.wikipedia.org/wiki/TortoiseGit" rel="noreferrer">TortoiseGit</a> and msysgit on a Windows platform if it helps.</p>