maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bidlo <>
Subject How to create new directory in target folder with Maven
Date Fri, 06 Sep 2013 20:06:05 GMT
I am writing a library which will create a report based on the test results
(imagine something like Surefire). And my problem is, I am able to create a
folder in target/ directory to hold the report and also copy there necessary
files but I can do that only when I build the library project itself.

I would like to achieve same behavior like a Surefire plugin has, that means
if I put dependency for my library to some project, let's say myProject,
then I will get something like myProject/target/myLibrary after the build.

btw, this is what I currently have

                        <echo message="Creating folder for the lib..." />
                        <mkdir dir="${report.folder}" />
                        <echo message="Copying Twitter Bootstrap libraries
to the ${report.folder}" />
                        <copy todir="${report.folder}">
                                <fileset dir="src/main/resources/bootstrap">
                                    <include name="**/**" />

I also tried to execute this code inside my library
FileUtils.copyDirectoryToDirectory(new File("src/main/resources/bootstrap"),
new File("target/myLibrary") but I will get obvious FileNotFoundException -
bootstrap doesn't exist in the project which is using the library

View this message in context:
Sent from the Maven - Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message