Reputation: 51113
I have a Gradle project with some dependencies that turned out not to be in Maven central. I tracked them down in the Typesafe repo and added
maven {
url 'http://repo.typesafe.com/typesafe/repo'
}
to my build.gradle
file, but Gradle continued to report the dependencies missing.
I guessed fairly quickly that what I was looking at was the equivalent of Maven's failure to find X in Y was cached in the local repository, resolution will not be reattempted but there wasn't any obvious way (cf mvn -U
) to tell Gradle to un-cache that failure.
Eventually I tried adding {changing = true}
to that family of dependencies, which apparently told Gradle to try those again, and it found them just fine. I suppose I could also have blown away my whole artifact cache. But it seems like there should be a faster way to fix this. Is there an easy way to either:
Upvotes: 2
Views: 353
Reputation: 123910
The equivalent to mvn -U
is gradle --refresh-dependencies
. Type gradle -h
to see all command line options.
Upvotes: 2