Folders under src/main/resources are not renamed according to groupId when 
creating project from archetype
----------------------------------------------------------------------------------------------------------

                 Key: ARCHETYPE-260
                 URL: http://jira.codehaus.org/browse/ARCHETYPE-260
             Project: Maven Archetype
          Issue Type: Bug
            Reporter: Geir Pettersen


We have a template project which we use to create archetypes from using the 
'mvn archetype:create-from-project' command. This template project has some 
configuration files that we stick under src/main/resources/<groupId>/config.xml 
- if the project's groupId is "org.company.templateApp" the path would be 
src/main/resources/org/company/templateApp". We do the same for some sample 
source code which we put under "src/main/java/<groupId>/Hello.java"

When we create a project from this template we see that the Hello.java is moved 
to a folder corresponding to the new project's groupId. When using groupId 
"org.company.myapp" maven would for instance  put our Hello.java in 
"src/main/java/org/company/myapp". This is a feature that we think is great, 
but it does not work with files that are in the "src/main/resources" -folder. 
Our config.xml which was located in 
"src/main/resources/org/company/templateApp/config.xml" is not moved to 
"src/../resources/o../c../myapp" in the newly created project. 

Our workaround for this issue is to put the xml config files in src/main/java 
instead. This is a solution that works for us (files are put in expected 
folders), but it goes against the idea of having separate java and resources 
folders, or at least it means that developers have to manually move these files 
after creating a project from the archetype.

Is this a bug? 
or is this a feature not intended for files in src/main/resources? If so, why 
not?



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to