Skip to content

Commit

Permalink
Prevent caching dependencies under jenkins
Browse files Browse the repository at this point in the history
  • Loading branch information
LunNova committed May 19, 2017
1 parent eddc85e commit 701d8ad
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,11 @@ buildscript {
url = "https://repo.nallar.me/"
}
}
configurations.all {
resolutionStrategy.cacheChangingModulesFor 1, 'hours'
resolutionStrategy.cacheDynamicVersionsFor 1, 'hours'
if (System.getenv("GRADLE_NO_CACHE_CHANGING") != null) {
configurations.all {
resolutionStrategy.cacheChangingModulesFor 1, 'seconds'
resolutionStrategy.cacheDynamicVersionsFor 1, 'seconds'
}
}
dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:2.2-SNAPSHOT'
Expand Down Expand Up @@ -46,9 +48,11 @@ repositories {
maven { url = 'https://repo.nallar.me/' }
}

configurations.all {
resolutionStrategy.cacheChangingModulesFor 1, 'hours'
resolutionStrategy.cacheDynamicVersionsFor 1, 'hours'
if (System.getenv("GRADLE_NO_CACHE_CHANGING") != null) {
configurations.all {
resolutionStrategy.cacheChangingModulesFor 1, 'seconds'
resolutionStrategy.cacheDynamicVersionsFor 1, 'seconds'
}
}

dependencies {
Expand Down

0 comments on commit 701d8ad

Please sign in to comment.