2
に1つのgitのレポからサブフォルダを移動する私は小さなものに一つの大きなレポを分割する典型的な問題を抱えているので、私が検索し、この出くわし:http://gbayer.com/development/moving-files-from-one-git-repository-to-another-preserving-history/別の保存の歴史
git clone <git repository A url>
cd <git repository A directory>
git remote rm origin
git filter-branch --subdirectory-filter <directory 1> -- --all
mkdir <directory 1>
mv * <directory 1>
git add .
git commit
それは私のために働いているだろう私のクローンは浅いものです。レポが大きいので、深さ0で複製する必要がありました。
私のオプションは何ですか?
はI必要があります。
- クローンは、最初の段階で、その完全な深さでのレポ(OR)
- ステップ3でリモートを切り離し、サブディレクトリを濾過した後、すべてをフェッチ(OR)
- ない何かを行います?