Skip to content

Instantly share code, notes, and snippets.

@alch
Created April 4, 2014 10:41
Show Gist options
  • Save alch/9972081 to your computer and use it in GitHub Desktop.
Save alch/9972081 to your computer and use it in GitHub Desktop.
Clone and subtree-split for Elcodi Bundles
#!/bin/bash
for i in $(ls -1 symfony.Elcodi/src/Elcodi/); do
rm -rf elcodi.$i
git clone [email protected]:elcodi/elcodi.git elcodi.$i;
cd elcodi.$i;
git filter-branch --prune-empty --subdirectory-filter src/Elcodi/$i;
git remote rm origin
git remote add origin [email protected]:elcodi/$i.git
git push origin master
git push --tags
cd ..
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment