我们有一个用于60+组件的主构建脚本。各个组件没有build.gradle文件。我要做的是以编程的方式(在主build.gradle中)向某些项目添加一个资源文件夹。此资源文件夹包含运行单元测试时必须在类路径中的文件。我试图在subprojects块中添加如下内容:
subprojects { proj ->
...
// this is the folder I need in the test task classpath
def resdir = sprintf("%s\\resources", project(':Common').projec
我正在写一个自定义插件在buildSrc使用Android Studio北极福克斯安装由brew。经过一些测试后,导入的自动完成功能出现了问题。在app/build.gradle.kts中,我可以使用import com.android.build.api.dsl.*,但在buildSrc中,这引发了Unresolved reference on android命名空间。 根build.gradle.kts // Top-level build file where you can add configuration options common to all sub-projects/mo
在gradle中加载复合项目时出现以下错误: Could not resolve de.demo.project.
Required by:
project :
Possible solution:
- Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html settings.gradle.kts: rootProject.name = "demoname