12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- <assembly>
- <!--
- assembly 打包配置更多配置可参考官司方文档:
- http://maven.apache.org/plugins/maven-assembly-plugin/assembly.html
- -->
- <id>release</id>
- <!--
- 设置打包格式,可同时设置多种格式,常用格式有:dir、zip、tar、tar.gz
- dir 格式便于在本地测试打包结果
- zip 格式便于 windows 系统下解压运行
- tar、tar.gz 格式便于 linux 系统下解压运行
- -->
- <formats>
- <format>dir</format>
- <format>zip</format>
- <!-- <format>tar.gz</format> -->
- </formats>
- <!-- 打 zip 设置为 true 会在包在存在总目录,打 dir 时设置为 false 少层目录 -->
- <includeBaseDirectory>true</includeBaseDirectory>
- <fileSets>
- <!--JunirRay 修改 src/main/resources 部分配置文件(排除mybatis的xml) copy 到 config 目录下 -->
- <fileSet>
- <directory>${basedir}/src/main/resources</directory>
- <outputDirectory>conf</outputDirectory>
- <!--juniorRay 新增-->
- <includes>
- <include>*.txt</include>
- <include>*.yml</include>
- <include>*.properties</include>
- <!--juniorRay 提示这里不要用*.xml否则会把mybatis的xml打进去造成无法启动-->
- <include>/*.xml</include><!-- ‘/’ 只包含根目录下的xml,子文件不进行遍历 -->
- <!--JuniorRay 或者直接不用上面的,用下面这个指定具体文件-->
- <!-- <include>ehcache.xml</include>
- <include>logback.xml</include>-->
- </includes>
- </fileSet>
- <!-- src/main/webapp 全部 copy 到 webapp 目录下 -->
- <fileSet>
- <directory>${basedir}/src/main/webapp</directory>
- <outputDirectory>webapp</outputDirectory>
- </fileSet>
- <!-- 项目根下面的脚本文件 copy 到根目录下 -->
- <fileSet>
- <directory>${basedir}</directory>
- <outputDirectory></outputDirectory>
- <!-- 脚本文件在 linux 下的权限设为 755,无需 chmod 可直接运行 -->
- <fileMode>755</fileMode>
- <includes>
- <include>*.sh</include>
- <include>*.bat</include>
- <!--JuniorRay 添加日志收集-->
- <include>logs</include>
- </includes>
- </fileSet>
- <fileSet>
- <directory>${basedir}/src/main/resources/lib</directory>
- <outputDirectory>lib</outputDirectory>
- <includes>
- <include>*.jar</include>
- </includes>
- </fileSet>
- </fileSets>
- <!-- 依赖的 jar 包 copy 到 lib 目录下 -->
- <dependencySets>
- <dependencySet>
- <outputDirectory>lib</outputDirectory>
- </dependencySet>
- </dependencySets>
- </assembly>
|