<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.kingsoft.test</groupId>
<artifactId>hello-world</artifactId>
<packaging>jar</packaging>
<version>0.0.1-SNAPSHOT</version>
<name>hello-world</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<!-- 插件定义 -->
<plugins>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>zip_setting</id>
<phase>package</phase>
<configuration>
<tasks>
<exec
executable="C:/baidu download/zip.bat" //${basedir}
>
</exec>
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- 打包插件 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.1.1</version>
<configuration>
<webappDirectory>
${basedir}/src/main/webapp
</webappDirectory>
<warSourceDirectory>
${basedir}/src/main/webapp
</warSourceDirectory>
<outputDirectory>
${basedir}/target/output
</outputDirectory>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<!-- not append assembly id in release file name -->
<appendAssemblyId>false</appendAssemblyId>
<archiverConfig>${artifactId}-sdk</archiverConfig>
<descriptors>
<descriptor>src/main/assemble/package.xml</descriptor>
</descriptors>
<finalName>${artifactId}-sdk</finalName>
<outputDirectory>${project.basedir}/target/release</outputDirectory>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
<finalName>${artifactId}-app</finalName>
</build>
<profiles>
<profile>
<!-- "Profile Build" contains a subset of "Project Build"s elements -->
<build> <finalName>${artifactId}-sdk</finalName></build>
</profile>
</profiles>
</project>