开发者

SVN Branch for migrating ANT to MAVEN2

I am looking to migrate several projects that are using ANT to MAVEN2.

The current SVN structure of the projects is:

trunk/project1/src/com

trunk/project2/src/com

...

My plan is to make a new maven_migration branch and move the folders to look like:

branches/project1/src/main/java/com

branches/project2/src/main/java/com

...

Once my work is complete I plan to merge the开发者_高级运维 branch back with the /trunk.

Will SVN know to merge file changes in the /trunk to their new paths?

will it handle files that were added and deleted to the /trunk after branchning?

Thanks, ny


Sorry, Subversion will not handle files (or directories) that were modified, added or deleted to trunk after branching and making the alterations as you are indicating.

However, if you do this right, you should be able to merge trunk/src/com to branch/src/main/java/com periodically to make the migration process a bit easier for those files that are modified, added, and deleted. Then when you are ready to merge the branch back to trunk, all of that should merge cleanly.

Those periodic merges to the branch from the trunk also assume that your not changing the source structure past /src/main/java/com either. If the plan is to break up your source to be a multi-module project in Maven, the number of merges to keep trunk in sync with the branch could become very challenging.

A procedural warning though, if you want to keep the history of those files that were moved for the migration, be sure to use svn copy and do not use svn move or svn rename when you move the source from /src/com to /src/main/java/com.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜