No, you should have two separate projects. That's the Maven way - do
yourself a favor and don't fight it!

/Anders

On Fri, Mar 5, 2010 at 10:11, WriteJava <[email protected]> wrote:

>
> Thanks for your reply Anders, yes I am trying to build both jar and sar
> within same maven project and I've some java classes which i need to add to
> sar and exclude others and add them to jar. Is this possible?
>
> Thanks
>
> Anders Hammar wrote:
> >
> > The exclude tag is for specifying artifactId:groupId as stated in the
> > docs.
> >
> > I don't understand why you don't want to include the classes? If you have
> > a
> > sar project but don't want to include some classes, why do you have them
> > in
> > that project? Or could it be that you're trying to do a jar AND a sar in
> > the
> > same Maven project?
> >
> > /Anders
> >
> > On Thu, Mar 4, 2010 at 17:06, WriteJava <[email protected]> wrote:
> >
> >>
> >> Hi,
> >>
> >> I am trying to generate a sar file using 'jboss-packaging-maven-plugin'
> >> plugin and I can't exclude .class files from my sar. It is including all
> >> classes to sar. Can you please help? Here is my code snippet:
> >>
> >>            <plugin>
> >>                <groupId>org.codehaus.mojo</groupId>
> >>                <artifactId>jboss-packaging-maven-plugin</artifactId>
> >>                <version>2.1.1</version>
> >>                <extensions>true</extensions>
> >>                <configuration>
> >>                        <excludes>
> >>                                <exclude>**/*.class</exclude>
> >>                        </excludes>
> >>                </configuration>
> >>                <executions>
> >>                    <execution>
> >>                        <id>sar123</id>
> >>                        <goals>
> >>                            <goal>sar</goal>
> >>                        </goals>
> >>                        <phase>package</phase>
> >>                        <configuration>
> >>                            <archiveName>my-service</archiveName>
> >>
> >>
> >>
> <deploymentDescriptorFile>${basedir}/conf/mysarMETA-INF/jboss-service.xml</deploymentDescriptorFile>
> >>                            <primaryArtifact>false</primaryArtifact>
> >>                        </configuration>
> >>                    </execution>
> >>                </executions>
> >>            </plugin>
> >>
> >> Thanks
> >> --
> >> View this message in context:
> >>
> http://old.nabble.com/Unable-to-exclude-.class-files-tp27782829p27782829.html
> >> Sent from the Maven - Users mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [email protected]
> >> For additional commands, e-mail: [email protected]
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://old.nabble.com/Unable-to-exclude-.class-files-tp27782829p27791501.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to