|
@@ -117,10 +117,32 @@
|
|
</execution>
|
|
</execution>
|
|
</executions>
|
|
</executions>
|
|
</plugin>
|
|
</plugin>
|
|
-
|
|
|
|
|
|
+ <plugin>
|
|
|
|
+ <artifactId>maven-resources-plugin</artifactId>
|
|
|
|
+ <executions>
|
|
|
|
+ <execution>
|
|
|
|
+ <id>copy-resources</id>
|
|
|
|
+ <phase>package</phase>
|
|
|
|
+ <goals>
|
|
|
|
+ <goal>copy-resources</goal>
|
|
|
|
+ </goals>
|
|
|
|
+ <configuration>
|
|
|
|
+ <resources>
|
|
|
|
+ <resource>
|
|
|
|
+ <directory>src/main/resources/</directory>
|
|
|
|
+ <includes>
|
|
|
|
+ <include>**/*.yml</include>
|
|
|
|
+ </includes>
|
|
|
|
+ </resource>
|
|
|
|
+ </resources>
|
|
|
|
+ <outputDirectory>${project.build.directory}/config</outputDirectory>
|
|
|
|
+ </configuration>
|
|
|
|
+ </execution>
|
|
|
|
+ </executions>
|
|
|
|
+ </plugin>
|
|
<!-- 按照测试要求打成zip需要的配置 -->
|
|
<!-- 按照测试要求打成zip需要的配置 -->
|
|
<!--获取git信息-->
|
|
<!--获取git信息-->
|
|
- <plugin>
|
|
|
|
|
|
+ <!--<plugin>
|
|
<groupId>pl.project13.maven</groupId>
|
|
<groupId>pl.project13.maven</groupId>
|
|
<artifactId>git-commit-id-plugin</artifactId>
|
|
<artifactId>git-commit-id-plugin</artifactId>
|
|
<executions>
|
|
<executions>
|
|
@@ -134,7 +156,7 @@
|
|
<verbose>true</verbose>
|
|
<verbose>true</verbose>
|
|
<dateFormat>yyyyMMddHHmm</dateFormat>
|
|
<dateFormat>yyyyMMddHHmm</dateFormat>
|
|
<generateGitPropertiesFile>true</generateGitPropertiesFile>
|
|
<generateGitPropertiesFile>true</generateGitPropertiesFile>
|
|
- <!--<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>-->
|
|
|
|
|
|
+ <!–<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>–>
|
|
<generateGitPropertiesFilename>target/git.properties</generateGitPropertiesFilename>
|
|
<generateGitPropertiesFilename>target/git.properties</generateGitPropertiesFilename>
|
|
</configuration>
|
|
</configuration>
|
|
</plugin>
|
|
</plugin>
|
|
@@ -150,13 +172,13 @@
|
|
<goal>rename</goal>
|
|
<goal>rename</goal>
|
|
</goals>
|
|
</goals>
|
|
<configuration>
|
|
<configuration>
|
|
-<!-- <sourceFile>${project.build.directory}/git.properties</sourceFile>-->
|
|
|
|
|
|
+<!– <sourceFile>${project.build.directory}/git.properties</sourceFile>–>
|
|
<destinationFile>${project.build.directory}/version.txt</destinationFile>
|
|
<destinationFile>${project.build.directory}/version.txt</destinationFile>
|
|
</configuration>
|
|
</configuration>
|
|
</execution>
|
|
</execution>
|
|
</executions>
|
|
</executions>
|
|
</plugin>
|
|
</plugin>
|
|
- <!--拷贝资源文件 copy-resources-->
|
|
|
|
|
|
+ <!–拷贝资源文件 copy-resources–>
|
|
<plugin>
|
|
<plugin>
|
|
<artifactId>maven-resources-plugin</artifactId>
|
|
<artifactId>maven-resources-plugin</artifactId>
|
|
<executions>
|
|
<executions>
|
|
@@ -184,7 +206,7 @@
|
|
<outputDirectory>${project.build.directory}/config</outputDirectory>
|
|
<outputDirectory>${project.build.directory}/config</outputDirectory>
|
|
</configuration>
|
|
</configuration>
|
|
</execution>
|
|
</execution>
|
|
- <!--拷贝启动脚本-->
|
|
|
|
|
|
+ <!–拷贝启动脚本–>
|
|
<execution>
|
|
<execution>
|
|
<id>copy-version</id>
|
|
<id>copy-version</id>
|
|
<phase>package</phase>
|
|
<phase>package</phase>
|
|
@@ -203,14 +225,14 @@
|
|
</executions>
|
|
</executions>
|
|
</plugin>
|
|
</plugin>
|
|
|
|
|
|
- <!-- 打包压缩 -->
|
|
|
|
|
|
+ <!– 打包压缩 –>
|
|
<plugin>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-assembly-plugin</artifactId>
|
|
<artifactId>maven-assembly-plugin</artifactId>
|
|
<executions>
|
|
<executions>
|
|
<execution>
|
|
<execution>
|
|
<id>make-assembly</id>
|
|
<id>make-assembly</id>
|
|
- <!-- 当执行mvn package时才会打包 -->
|
|
|
|
|
|
+ <!– 当执行mvn package时才会打包 –>
|
|
<phase>package</phase>
|
|
<phase>package</phase>
|
|
<goals>
|
|
<goals>
|
|
<goal>single</goal>
|
|
<goal>single</goal>
|
|
@@ -219,17 +241,17 @@
|
|
<finalName>
|
|
<finalName>
|
|
${project.artifactId}_${git.commit.time}_git_${git.branch}_${git.commit.id.abbrev}
|
|
${project.artifactId}_${git.commit.time}_git_${git.branch}_${git.commit.id.abbrev}
|
|
</finalName>
|
|
</finalName>
|
|
- <!--不包含assembly id-->
|
|
|
|
|
|
+ <!–不包含assembly id–>
|
|
<appendAssemblyId>false</appendAssemblyId>
|
|
<appendAssemblyId>false</appendAssemblyId>
|
|
- <!--输出路径-->
|
|
|
|
- <!--<outputDirectory>../target/co_search-${project.version}</outputDirectory>-->
|
|
|
|
|
|
+ <!–输出路径–>
|
|
|
|
+ <!–<outputDirectory>../target/co_search-${project.version}</outputDirectory>–>
|
|
<descriptors>
|
|
<descriptors>
|
|
<descriptor>src/script/zip.xml</descriptor>
|
|
<descriptor>src/script/zip.xml</descriptor>
|
|
</descriptors>
|
|
</descriptors>
|
|
</configuration>
|
|
</configuration>
|
|
</execution>
|
|
</execution>
|
|
</executions>
|
|
</executions>
|
|
- </plugin>
|
|
|
|
|
|
+ </plugin>-->
|
|
</plugins>
|
|
</plugins>
|
|
</build>
|
|
</build>
|
|
|
|
|