In cases of web projects, src/main/resources are copied into web-inf/classes

Edwin Punzalan wrote:


If your packaging is war, files from src/main/webapp are copied into your war archive root. Please use this.

src/main/resources are always copied into target/classes.



Karthik V wrote:

I have a war project in m2 and want to copy some resource files to target.
In my src/main/resources folder, I have some files, along with a web-inf
folder containing some more files. But maven always seems to copy it to
target/web-inf/classes and not target. How do I change this behavior?

I tried adding something like
   <resources>
       <directory>${basedir}/src/main/resources</directory>
       <targetPath>target</targetPath>
     </resource>
   </resources>


but it didnt help... the above copied the files to
target/web-inf/classes/target.


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


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

Reply via email to