简体   繁体   English

如何将 -X 和 -B 等命令行参数传递给 Artifactory Maven 插件中的 rtMavenRun?

[英]How to pass command line parameters like -X and -B to rtMavenRun in Artifactory Maven Plugin?

In my declarative Jenkinsfile, I am invoking maven with this block sourced from https://www.jfrog.com/confluence/display/RTF/Working+With+Pipeline+Jobs+in+Jenkins在我的声明性 Jenkinsfile 中,我正在使用来自https://www.jfrog.com/confluence/display/RTF/Working+With+Pipeline+Jobs+in+Jenkins 的这个块调用 maven

 rtMavenRun ( tool: 'maven-3.6.0', pom: 'pom.xml', goals: 'clean test', resolverId: 'maven-resolver-id', deployerId: 'maven-deployer-id', buildNumber: '99', buildName: 'my-build' )

When it runs, the output is flooded with lots of 'Progress' entries.当它运行时,输出中充斥着许多“进度”条目。 The way to turn that off is the use -B on the mvn command line.关闭它的方法是在 mvn 命令行上使用 -B 。

How to do so using rtMavenRun() ?如何使用 rtMavenRun() 做到这一点?

I tried using the 'options:' parameter found https://jenkins.io/doc/pipeline/steps/artifactory/#rtmavenrun-run-artifactory-maven but that only defines JVM parameters rather than maven parameters.我尝试使用找到的“选项:”参数https://jenkins.io/doc/pipeline/steps/artifactory/#rtmavenrun-run-artifactory-maven但它只定义了 JVM 参数而不是 maven 参数。

将 'goals' 参数更改为具有值'-B clean test'

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM