I have a project with SNAPSHOT dependencies using gradle as its build tool in intellij.
The problem is that intellij is using SNAPSHOTS that are now outdated.
When I build the project on the command line
gradle build or
gradle clean build --refresh-dependencies
On command line the latest dependencies are fetched. I also setup my grade file to always download snapshot dependencies according to this answer.
How can I force intellij to download all dependencies?
I have run into some very sticky snapshots. There are a few options you can try:
configurations.all {
resolutionStrategy.cacheDynamicVersionsFor 4, 'hours'
resolutionStrategy.cacheChangingModulesFor 4, 'hours'
}
This config change is a last-ditch option and should be used sparingly. It basically tells Gradle to refresh the local cache more often. You should click the IntelliJ Gradle refresh button after making these changes.