Last active
March 23, 2016 05:18
-
-
Save wataru420/6247700 to your computer and use it in GitHub Desktop.
gitの特定のディレクトリをブランチ毎別リポジトリにする方法 ref: http://qiita.com/wataru420/items/f1eb7cf37fe5ba4980c3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mkdir ~/subproject |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ~/ | |
git clone baseproject subproject |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ~/subproject/ | |
git filter-branch --subdirectory-filter subproject -- --all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git branch -a |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git checkout -b origin/feature001 | |
git checkout -b origin/feature002 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git remote rm origin | |
git remote add origin [email protected]:hoge/subproject.git | |
git push --all |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment