我应该在哪里把Jenkins中的gradle.properties [英] Where should I put gradle.properties in Jenkins

查看:653
本文介绍了我应该在哪里把Jenkins中的gradle.properties的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我应该在Jenkins中放置gradle.properties文件吗?



我使用的是Gradle插件的1.21版本,但它没有找到属性文件当我将它放在用户主目录.gradle目录中时。



任何指针都会非常感谢。



谢谢

UPDATED

Gradle插件默认在每个项目的工作区中显示为gradle.properties文件。为了在所有作业中使用一个文件,您需要在您的作业配置中设置您的gradle,如下所示,在'switches'下添加以下内容:

  -Dgradle.user.home = $ HOME / .gradle 


解决方案

默认情况下,Gradle插件在每个项目的工作空间中查找gradle.properties文件。为了在所有作业中使用一个文件,您需要在您的作业配置中设置您的gradle,如下所示,在'switches'下添加以下内容:

  -Dgradle.user.home = $ HOME / .gradle 


Where should I put the gradle.properties file in Jenkins?

I'm using version 1.21 of the Gradle plugin, but it isn't finding the properties file when I put it in the user home .gradle directory.

Any pointers would be much appreciated.

Thanks

UPDATED

The Gradle plugin looks by default in the workspace of each project for a gradle.properties file. In order to use one file across all jobs, you need to set your gradle home in your job configurations as follows, by adding the following under 'switches':

-Dgradle.user.home=$HOME/.gradle

解决方案

The Gradle plugin looks by default in the workspace of each project for a gradle.properties file. In order to use one file across all jobs, you need to set your gradle home in your job configurations as follows, by adding the following under 'switches':

-Dgradle.user.home=$HOME/.gradle

这篇关于我应该在哪里把Jenkins中的gradle.properties的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆