> -----Original Message-----
> From: Moritz Petersen [mailto:[EMAIL PROTECTED]
> Sent: Sunday, July 27, 2003 12:52 PM
> To: [EMAIL PROTECTED]
> Subject: Problem with beta-10 and java:jar-resources again
> 
> 
> This was discussed before, but the solution did not fit my problem.
> 
> The resources are not copied to the target/classes directory.
> 
> When I run maven -X java:jar-resources, I notice, that
> 
> -----------%<-------------
> 
> [DEBUG] Adding reference: maven.jar.resources.set -> patternSet{ 
> includes: [] excludes: [] }
> 
> ----------->%-------------
> 
> there are no includes, but my project.xml has some defined:
> 
> -----------%<-------------
> 
>      <build>
>          <sourceDirectory>src/java</sourceDirectory>
>          <unitTestSourceDirectory>src/test/java</unitTestSourceDirectory>
>               <resources>
>                       <includes>
>                               <include>**/*.properties</include>
>                               <include>**/*.xml</include>
>                       </includes>
>               </resources>
>      </build>
> 
> ----------->%-------------
> 
> and the src/java directory contains the files
> 
> log4j.properties
> application.xml
> 
> Can anyone tell me, why this doesn't work and what I have to do to make 
> it work? Thank you,
> 
> 
> -Mo.
> 

1. Don't keep your resources in src/java
2. Do something like:

    <!-- J A R  R E S O U R C E S -->
    <!-- Resources that are packaged up inside the JAR file -->
    <resources>
      <resource>
        <directory>${basedir}/src/resources/messages</directory>
        <targetPath>com/xxx/yyy</targetPath>
        <includes>
          <include>Messages*.properties</include>
        </includes>
      </resource>
      
      <resource>
        <directory>${basedir}/src/resources/logging</directory>
        <includes>
          <include>log4j.properties</include>
        </includes>
      </resource>
    </resources>



Michal


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to