Let's say I've got two repositories aye
and bee
and I want to get rid of bee
, in such a way that the linear history of bee/master
is "replayed" in a new subdirectory (several levels deep) of aye
. I just want the files and the commit messages, I don't care about commit IDs. I do want a sensible history, so git subtree add --prefix=subdirectory
and git read-tree --prefix=subdirectory/
are not what I'm looking for.
Both repositories are private, so there's no risk of rewriting history for someone else. However, bee
does have a submodule cee
.
/usr/lib/git-core/git-filter-branch: 3: eval: [[: not found
. Had to remove lines withif
,then
andfi
and job was done, thanks! Ubuntu 18.04; git 2.22.0; bash 4.4.20 – d9k Jul 26 '19 at 17:44