Skip to content

Instantly share code, notes, and snippets.

@samth
Created May 21, 2013 07:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save samth/5618014 to your computer and use it in GitHub Desktop.
Save samth/5618014 to your computer and use it in GitHub Desktop.
splitting
[samth@hermes:~/tmp plt] git clone ~/sw/plt/
[samth@hermes:~/tmp/plt (master) plt] git filter-branch -f --prune-empty --tag-name-filter cat --subdirectory-filter collects/realm/ -- --all
[samth@hermes:~/tmp/plt (master) plt] git filter-branch -f --index-filter 'git ls-files -s | sed "s-\t\"*-&realm/-" |
GIT_INDEX_FILE=$GIT_INDEX_FILE.new \
git update-index --index-info &&
mv "$GIT_INDEX_FILE.new" "$GIT_INDEX_FILE"' HEAD
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment