2010-06-10 75 views
6

我有以下语法问题。在Maven组装描述符中排除jar包中的包

我有一个从其他解压缩的jar文件创建的jar文件。 我想排除一些包在新的jar文件。

这里是我的装配描述

<assembly> 
<id>gs-jar</id> 
<formats> 
    <format>jar</format> 
</formats> 
<includeBaseDirectory>false</includeBaseDirectory> 

<dependencySets> 
    <dependencySet> 
     <unpack>true</unpack> 
     <scope>runtime</scope> 
     <includes> 
      <include>com.delver:shci-commons</include> 
      <include>com.delver:shci-model</include> 
      <include>com.delver:gigaspaces-persistence</include> 
      <include>com.delver:gigaspaces-mirror</include> 
      <include>com.delver:recommendation</include> 
     </includes> 
     <unpackOptions> 
      <excludes> 
       <exclude> 
        Ohio.Model* 
       </exclude> 
       <exclude>log4j.properties</exclude> 
       <exclude>gslicense.xml</exclude> 
      </excludes> 
     </unpackOptions> 
    </dependencySet> 
</dependencySets> 
</assembly> 

正如你看到的我试图排除与Ohio.Model启动程序包,但不知何故,得到小号反正包括在内。

语法有问题吗?

回答

4

发现它

  <exclude> 
       **/Ohio/** 
      </exclude>