You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Osborne, Matthew" <Ma...@suny.edu> on 2005/11/30 17:32:34 UTC

Changing default source code directory structure

Hello
     I have a question regarding Maven archetypes.  As I mentioned in a
previous post, I am currently porting an existing project we have here
at work from ANT to Maven 2.0.  In this process, I am trying to disturb
the directory structure of our project as little as possible.  I have
just encountered another problem thats causing me mondo headaches - I am
trying to redefine the default maven code directory structure in my
<archetype.xml> file to fit our project's code structure, but as soon as
I change the settings and I try to compile my code, maven ignores my
source code completely.  The only way I can get it to see and compile my
code is if I change my source code's directory structure to match their
default structure.  Is there someplace else where I can change this
setting, or am I pretty much restricted to nothing but the default
directory structure?

Matthew Osborne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Changing default source code directory structure

Posted by Piéroni Raphaël <ra...@gmail.com>.
Hello Matthew,

In http://maven.apache.org/guides/introduction/introduction-to-the-pom.html

you can find :
<build>
    <directory>target</directory>
    <outputDirectory>target/classes</outputDirectory>
    <finalName>${artifactId}-${version}</finalName>
    <testOutputDirectory>target/test-classes</testOutputDirectory>
    <sourceDirectory>src/main/java</sourceDirectory>
    <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
    <testSourceDirectory>src/test/java</testSourceDirectory>
    <resources>
      <resource>
        <directory>src/main/resources</directory>
      </resource>
    </resources>
    <testResources>
      <testResource>
        <directory>src/test/resources</directory>
      </testResource>
    </testResources>

May that helps.

Regards,

Raphaël

2005/11/30, Osborne, Matthew <Ma...@suny.edu>:
> Hello
>      I have a question regarding Maven archetypes.  As I mentioned in a
> previous post, I am currently porting an existing project we have here
> at work from ANT to Maven 2.0.  In this process, I am trying to disturb
> the directory structure of our project as little as possible.  I have
> just encountered another problem thats causing me mondo headaches - I am
> trying to redefine the default maven code directory structure in my
> <archetype.xml> file to fit our project's code structure, but as soon as
> I change the settings and I try to compile my code, maven ignores my
> source code completely.  The only way I can get it to see and compile my
> code is if I change my source code's directory structure to match their
> default structure.  Is there someplace else where I can change this
> setting, or am I pretty much restricted to nothing but the default
> directory structure?
>
> Matthew Osborne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org