我一直在研究一个 Eclipse 插件项目,我遇到了一种情况,我需要拆分项目以将测试用例与插件包分开。我使用 git 作为版本控制。
为了简单地描述这一点,我正在像这样对旧项目进行版本控制:
workspace/
|
+-- myplugin/
|
+-- .git/ <-- Here be the git repository
|
+-- /* Source code, project stuff, etc. */
…而且我处于需要在单独的项目中进行插件测试的情况(这样就不需要将 jUnit 作为插件的必需捆绑包)。而且我希望存储库对工作区中的所有内容进行版本控制。像这样:
workspace/
|
+-- .git/ <-- The repository should be relocated here instead…
|
+-- myplugin/
| |
| +-- /* Source code, project stuff, etc. */
|
+-- myplugin-test/
|
+-- /* Unit tests and stuff… */
有没有一种简单的方法可以在不丢失旧项目历史的情况下做到这一点?