Hi there,

I was wondering if its possible to exclude a directory from the src
directory so that it is not packaged.

Following is the directory layout

Src
|---main
    |---java
        |---com
        |---abc
            |---my-project
            |---dir_dont_wanna_include

So when I do mvn package, it packages both my-project and
dir_dont_wanna_include directories in the package. Is it possible to not
include dir_dont_wanna_include directory? Or should I move it out of the
src directory all together. I don't wanna move this directory from src
is because it is java source but it actually is not the main project but
some java scripts that run periodically calling the main my-project code

I tried the following in my pom with no effect

<build>
        <plugins>
            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>2.0.2</version>
                <configuration>
                    <source>1.5</source>
                    <target>1.5</target>
                </configuration>
            </plugin>
        </plugins>
        
<sourceDirectory>src/main/java/com/abc/my-project/</sourceDirectory>
    </build>

Thanks

Shahzad Qureshi
Systems Analyst/Programmer
Applications Directorate, CIOB
Environment Canada
shahzad.qure...@ec.gc.ca

Reply via email to