Maven Plugins
2019独角兽企业重金招聘Python工程师标准>>>
Maven Resources Plugin
Specifying resource directories
<resources><resource><directory>resource1</directory></resource><resource><directory>resource2</directory></resource><resource><directory>resource3</directory></resource></resources>
Filtering
<resource><directory>src/main/resources</directory><filtering>true</filtering></resource>
But to organize your project, you may want to put all your variables and their values in a separate file so that you will not have to rewrite your POM, or set their values all the time with every build. This can be done by adding a filter.
<project>...<name>My Resources Plugin Practice Project</name>...<build>...<filters><filter>[a filter property]</filter></filters>...</build>...</project>
Including and excluding files and directories
<project>...<name>My Resources Plugin Practice Project</name>...<build>...<resources><resource><directory>src/my-resources</directory><includes><include>**/*.txt</include></includes><excludes><exclude>**/*test*.*</exclude></excludes></resource>...</resources>...</build>...</project>
Copy Resources
<project>...<build><plugins><plugin><artifactId>maven-resources-plugin</artifactId><version>3.1.0</version><executions><execution><id>copy-resources</id><!-- here the phase you need --><phase>validate</phase><goals><goal>copy-resources</goal></goals><configuration><outputDirectory>${basedir}/target/extra-resources</outputDirectory><resources> <resource><directory>src/non-packaged-resources</directory><filtering>true</filtering></resource></resources> </configuration> </execution></executions></plugin></plugins>...</build>...</project>
转载于:https://my.oschina.net/odetteisgorgeous/blog/3045677
Maven Plugins相关推荐
- 解决Failed to execute goal org.apache.maven.plugins
1.Maven构建失败 Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin: 2.3 . 2 :compile ...
- 报错: eclipse加载maven工程提示pom.xml无法解析org.apache.maven.plugins:maven-resources-plugin:2.3.2...
错误信息出现在pom头的project标签,project标签内容是 <project xmlns="http://maven.apache.org/POM/4.0.0" x ...
- 针对Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1的解决方案
2019独角兽企业重金招聘Python工程师标准>>> 背景:本项目使用JDK1.8 编译maven工程的时候出现如下错误: Failed to execute goal org.a ...
- Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.3:compile (default-compile)
完整的错误信息: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.3:compile ( ...
- 针对maven install 报错:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1 解决方案...
项目运行环境:jdk1.8+tomcat8 maven install 时报错:Failed to execute goal org.apache.maven.plugins:maven-compil ...
- Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test)
这是因为测试代码时遇到错误,它会停止编译.只需要在pom.xml的<project>里添加以下配置,使得测试出错不影响项目的编译.<build> <plugins> ...
- 解决:Cannot resolve plugin org.apache.maven.plugins:maven-compiler-plugin:2.3.2问题
出现Cannot resolve plugin org.apache.maven.plugins这类的问题原因基本都是一样的,都是导入本地仓库时出错,出错的原因可能是版本原因,也有其他原因. 解决办法 ...
- IDEA报错:Cannot resolve plugin org.apache.maven.plugins:*
导入项目时可能因为网络等因素造成maven的一些问题. 使用maven-deploy插件多年来遇到了这个问题,即使我没有在我的POM中直接包含插件,也出现了错误. 作为一个解决方案我不得不强制将插件包 ...
- 【maven install报错】Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.2:war
maven install报错如下: [INFO] Scanning for projects... [INFO] Downloading: http://xxx.xx.xx.x:xxxx/nexus ...
- 【maven install报错】Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile
maven install之后报的错误如下: [INFO] Scanning for projects... [INFO] Downloading: http://xxx.xxx.xxx.xxx:xx ...
最新文章
- 4大主流CPU处理器技术架构,不知道就out了!
- decose oracle_oracle 内存与进程
- nyoj 208 Supermarket(贪心)
- .mvn 需要放git上吗_下巴反复长痘,饮食上需要忌口吗?
- Fiori Elements setBusyIndicatorDelay调试的几个关键点
- 女性开车5大安全驾车好习惯 为您支招
- managed code和unmanaged code混合debug
- 安卓Toast显示提示消息(自定义view,根据子线程消息显示提示)
- delphi socket 怎样把接收到的二进制数据转换成字符串显示_【连载电子书二】Python基础数据类型详解(上)...
- Centos 7.2 安装Docker CE实践并配置加速器
- 自监督学习经典之作:DINO
- 想知道视频水印怎么去?推荐几个去视频水印的方法
- python文件查重_文件查重 我使用的是面向局部敏感的最小哈希签名的方法进行文档查重 联合开发网 - pudn.com...
- 超详细的R语言热图之complexheatmap系列(1)
- 如何用A4纸排版打印并制作成四分之一大小的册子(简易说明书)
- Unity 在Mac上打包,执行python报Win32Exception的解决方案
- Windows下安装Boot Camp提示版本不适用
- BrandTech如何提高种草爆文率?
- 计算机一级电脑在线模拟,2017全国计算机一级考试模拟试题
- 数据库厂商都怕低价竞争?阿里云说竞争靠核心技术