简体   繁体   English

詹金斯:如何用不依赖关系完成Gradle构建?

[英]Jenkins: How to complete a Gradle build with dependencies not in nexus?

I have a Gradle based project that is dependent on a couple of other projects one built via maven another via gradle. 我有一个基于Gradle的项目,该项目依赖于其他两个项目,一个是通过Maven构建的,另一个是通过Gradle构建的。 I can't push the other projects to our "enterprise" nexus repo because that involves much time/paperwork/pain. 我不能将其他项目推到我们的“企业”联系回购中,因为这涉及很多时间/文书工作/痛苦。 So is there a workaround I can use. 所以有没有我可以使用的解决方法。 Locally we simply build the other two projects so they are in our local repo and then can pull them from there. 在本地,我们只需构建其他两个项目,使它们位于我们的本地仓库中,然后就可以将其从那里拉出来。 How can I achieve something similar on Jenkins? 我如何在詹金斯身上取得类似的成就? Each project is in a seprate Git repo. 每个项目都在单独的Git存储库中。

I think you can do exactly the same thing inside Jenkins. 我认为您可以在Jenkins中执行完全相同的操作。

Before starting to build the gradle project, try checkout other projects firstly, and build them, so it will be installed into your local repo. 在开始构建gradle项目之前,请先尝试签出其他项目并进行构建,这样它将被安装到您的本地仓库中。

Then build the gradle as you did locally. 然后像在本地一样构建gradle。

Br,

Tim 提姆

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

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