GradleGitDependenciesPlugin icon indicating copy to clipboard operation
GradleGitDependenciesPlugin copied to clipboard

Setting custom dir downloads to user home folder

Open tonisives opened this issue 2 years ago • 1 comments
trafficstars

If I set a custom dir in settings.gradle

git {
    dir './gradle-libs' // or just 'gradle-libs'
}

The build fails with: Creating directories for /Users/me/.gradle/daemon/7.4.2/./gradle-libs/kafka-internal-schemas/.git failed or Creating directories for /Users/me/.gradle/daemon/7.4.2/gradle-libs/kafka-internal-schemas/.git failed

Solution:

git {
    dir "${System.getProperty("user.dir")}/gradle-libs"
}

tonisives avatar Jan 09 '23 01:01 tonisives

Thanks for report, it is strange that dir 'gradle-libs' ends up under .gradle directory. I need to check what's going on.

I think it is a good idea to use absolute path anyway, you can also use "$rootDir/..." for paths relative to the project's root.

alexvasilkov avatar Jan 19 '23 15:01 alexvasilkov