更新时间:2023-12-05 15:45:34
调用 ant 就像使用 maven 一样(查看示例 https://jenkins.io/doc/pipeline/jenkinsfile/):
You invoke ant just like you do it with maven (take a look at examples https://jenkins.io/doc/pipeline/jenkinsfile/):
node ('linux'){
stage 'Build and Test'
env.PATH = "${tool 'Ant'}/bin:${env.PATH}"
checkout scm
sh 'ant build'
}
任务本身应该在 build.xml
中配置.
The tasks themselves should be configured in the build.xml
.