yueli...@gmail.com於 2017年6月17日星期六 UTC+8下午5時20分31秒寫道:
>
> rough steps:
>
> 0. suppose there are A and B branch in TheSubmodule repo, A is used by 
> ProjectA, and B is used by ProjectB
> 1. move Projects/ProjectA/.git/modules/TheSubmodule to a common folder, 
> say Projects/Common/TheSubmodule.
> 2. delete the key worktree of Projects/Common/TheSubmodule/config file
>

this step may be wrong. maybe modify the key worktree value to the correct 
one.
 

> 3. modify Projects/ProjectA/TheSubmodule/.git file, make the gitdir points 
> to the new path inner that common folder.
> 4. rename Projects/ProjectB/TheSubmodule to 
> Projects/ProjectB/TheOldSubmodule
> 5. run command `git worktree add ../../ProjectB/TheSubmodule B` in 
> Projects/ProjectA/TheSubmodule
> 6. delete Projects/ProjectB/TheOldSubmodule and 
> Projects/ProjectB/.git/modules/TheSubmodule
>
> Yue Lin Ho
>

-- 
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to git-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to