title: How to move part of git branch to different repo?
body: <p>Let assume that i have a git repo with commits:</p>
  <pre><code>H - add stuff
  G - add stuff
  F - add stuff
  E - remove big files
  D - add stuff
  C - add big files
  B - add stuff
  A - initial commit
  </code></pre>
  <p>I want to move this branch which is master to different repo from commit F to H without the stuff from A to E. Basically the new repo would contain squashed commits from A to E plus commits F,G and H.</p>
  <p>Update:
  Based on comments i tried the following, but it ended up in merge conflicts:</p>
  <pre><code>git checkout A
  git checkout -b cleanup
  git checkout master
  git rebase -i cleanup
  
  pick A
  squash B
  squash C
  squash D
  squash E
  pick F
  pick G
  pick H
  </code></pre>