2016-08-19 37 views
0

當我用maven-war-plugin得到一個war包,然後用maven-resources-plugin把這個war文件複製到另一個字典時,war文件從4M變大到8M。爲什麼在Maven copy-resources插件的複製操作之後文件變大了?

這裏是POM,

<build> 
    <plugins> 
     <plugin> 
      <artifactId>maven-war-plugin</artifactId> 
      <version>2.2</version> 
      <executions> 
       <execution> 
        <id>default-war</id> 
        <phase>package</phase> 
        <goals> 
         <goal>war</goal> 
        </goals> 
        <configuration> 
         <warName>FirstIssue</warName> 
        </configuration> 
       </execution> 
      </executions> 
     </plugin> 
     <plugin> 
      <artifactId>maven-resources-plugin</artifactId> 
      <version>3.0.1</version> 
      <executions> 
       <execution> 
        <id>copy-resources</id> 
        <phase>install</phase> 
        <goals> 
         <goal>copy-resources</goal> 
        </goals> 
        <configuration> 
         <outputDirectory>../../GTISServer/iis-gtis-web/src/main/webapp/downloadResource/firstIssue</outputDirectory> 
         <resources> 
          <resource> 
           <directory>target</directory> 
           <includes> 
            <include>FirstIssue.war</include> 
           </includes> 
           <filtering>true</filtering> 
          </resource> 
         </resources> 
        </configuration> 
       </execution> 
      </executions> 
     </plugin> 
    </plugins> 
</build> 

當我運行Maven:安裝在IDEA,我有兩個war文件,一個maven-war-plugin創建爲4M,由maven-resources-plugin創造另一種是8M。

我無法用任何zip工具打開這場8M大戰。

from 4M to 8M

回答

相關問題