title: Replace the contents of one directory in GIT
body: <p>Imagine that I have a repository with directories Dir1 and Dir2 and I am in branchA. </p>
  
  <p>Imagine that I want to get rid of contents of Dir2 and replace them with Dir2 in the master branch, while keeping the content of Dir1.</p>
  
  <p>I don't expect this to be that simple, but ideally :</p>
  
  <pre><code>cd Dir2
  git [magic that replaces current dir with the contents of master branch]
  </code></pre>