title: How to sync a subdirectory of a git repo?
body: <p>I want to <em>pull from</em> and <em>push to</em> only a subdirectory of a git repository. Here is an example of what I want to achieve:</p>
  
  <p>Let's say, I have a repository, containing two folders <code>A</code> and <code>B</code> (they are top-level folders, if that matters). I want to work and push changes into <code>B</code> only, while others are working on <code>A</code> and maybe even on <code>B</code> as well. Because I want to commit my changes back, I can't put <code>A</code> in the <code>.gitignore</code> file, nor I can use <code>git rm -rf --cached A</code>, since <code>A</code> is needed by others, however, I know, I will never touch any of the files it contains, and I simply don't want to store the unnecessary files of it. I can't use <code>submodules</code> either, as I don't want to change the original repository, nor I want to maintain a secondary one.</p>
  
  <p><strong>So my questions are:</strong> is this even possible; and if so, how can achieve this?</p>