<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-assembly-plugin</artifactId> <version>2.4</version> <configuration> <finalName>content</finalName> <appendAssemblyId>false</appendAssemblyId
</plugin> 3. 设置非项目代码的配置文件 <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-assembly-plugin</artifactId> <configuration> <appendAssemblyId>false</appendAssemblyId> target/ <!— 指定assembly配置文件路径 --> <descriptors> <descriptor>zip-desc.xml</descriptor> <...
</configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-assembly-plugin</artifactId> <configuration> <appendAssemblyId>false</appendAssemblyId> <!-- 下面是指定了插件的配置文件,用来说明哪些内容需要打包 --> <descriptors> <descriptor>src/main/assembly/ass...
maven-jar-plugin spring-boot-maven-plugin maven-dependency-plugin maven-resources-plugin 1.maven-assembly-plugin 配置assembly.xml文件路径 <plugin> <artifactId>maven-assembly-plugin</artifactId> <version>3.1.0</version> <configuration> <descriptors> <descriptor>src/main/assembly/assembly.xml</descripto...
打包后的目录结构类似于tomcat/maven目录结构 代码托管 Github|Gitee 主要插件 maven-assembly-plugin maven-jar-plugin spring-boot-maven-plugin maven-dependency-plugin maven-resources-plugin 1.maven-assembly-plugin 配置assembly.xml文件路径 <plugin>
1.spring-boot-maven-plugin:这个插件是springboot的maven插件,能够将springboot项目打包为可执行的jar/war,官网文档。 2.maven-assembly-plugin: 这个插件是maven结构定制化的打包,maven中针对打包任务而提供的标准插件,包含了以下几个插件的功能,官网文档。
其实就是综合了SpringBoot运行的插件spring-boot-maven-plugin和maven打包插件maven-assembly-plugin两种方式结合使用,大家可以直接复制!
# 使用maven-assembly-plugin进行配置分离 assembly.xml配置文件 代码语言:javascript 代码运行次数:0 运行 AI代码解释 <?xml version="1.0" encoding="UTF-8"?> <assembly> <!-- 可自定义,这里指定的是项目环境 --> <!-- xxx.tar.gz --> <id>${name}</id> <!-- 打包的类型,如果有N个,将会打N...
maven-assembly-plugin false jar-with-dependencies http://com.libii.sso.LibiiSpringBootStartApplication make-assembly package single 打包结果: springboot打包插件详解(spring-boot-maven-plugin) 引入配置 org.springframework.boot spring-boot-maven-plugin ...
</plugin> 2、把抽离的配置文件,放到conf目录下 利用maven-assembly-plugin,抽取配置文件到conf目录下, 示例代码: <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-assembly-plugin</artifactId> <version>3.3.0</version>