Search code examples
svnmavendirectory-structure

Modify project structure on subversion to use maven


I have a project created in Eclipse that has roughly this structure:

  • src
  • conf
  • test
  • WebContent
    • WEB-INF

When integrating with maven the structure should be more like this:

  • src
    • main
      • java
      • resources
      • webapp
        • WEB-INF
    • test

I can either modify the pom to work on the old structure, but I prefer to have the classic maven structure. Is there anyway to move the files in the new structure in order to keep their history? How can I do that?


Solution

  • You can move files/folders in SVN retaining history. See this related SO post. If you use subversion client integrated with Eclipse (subclipse or subversive), then you can do this within Eclipse itself, by choosing Refactor -> Rename../Move... and commit the changes.