From 0af88164b55e68ae2837c2b8c180f23ec19c76e8 Mon Sep 17 00:00:00 2001 From: Puneet Behl Date: Sat, 9 Mar 2024 19:49:42 +0530 Subject: [PATCH] chore(build): Migrate to Develocity build cache connector (#834) To simplify cache management with the [Develocity cache connector](https://docs.gradle.com/enterprise/gradle-plugin/#using_the_develocity_connector) --- settings.gradle | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/settings.gradle b/settings.gradle index bfda39f0..e483d7f6 100644 --- a/settings.gradle +++ b/settings.gradle @@ -13,19 +13,17 @@ gradleEnterprise { taskInputFiles = true } } + } buildCache { local { enabled = System.getenv('CI') != 'true' } - remote(HttpBuildCache) { - push = System.getenv('CI') == 'true' + remote(gradleEnterprise.buildCache) { + def isAuthenticated = System.getenv('GRADLE_ENTERPRISE_ACCESS_KEY') + push = System.getenv('CI') == 'true' && isAuthenticated enabled = true - url = 'https://ge.grails.org/cache/' - credentials { - username = System.getenv('GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER') - password = System.getenv('GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY') - } - }} + } +} // Core