What can I do to make the following Gradle project build succesfully?
I've build a new project. settings.gradle
is:
rootProject.name = 'myproject'
build.gradle
is:
group 'mygroup'
version '1.0-SNAPSHOT'
apply plugin: 'groovy'
apply plugin: 'java'
apply plugin: 'idea'
sourceCompatibility = 1.5
repositories {
mavenLocal()
mavenCentral()
maven { url "https://plugins.gradle.org/m2/" }
maven { url "https://mvnrepository.com/artifact/org.apache.commons/commons-lang3" }
}
dependencies {
compile group: 'org.apache.commons', name: 'commons-lang3', version: '3.6'
compile 'org.codehaus.groovy:groovy-all:2.3.11'
testCompile group: 'junit', name: 'junit', version: '4.11'
}
If I use "Refresh all gradle projects" in the Gradle Tool Window, the Event Log says:
Unindexed remote maven repositories found. [Disable...] The following repositories used in your gradle projects were not indexed yet: https://plugins.gradle.org/m2 https://mvnrepository.com/artifact/org.apache.commons/commons-lang3
Project Structure --> Problems tells me:
Library Gradle: org.apache.commons:commons-lang3:3.6 has broken classes path: /home/myhome/git/myproject/Could not resolve org.apache.commons:commons-lang3:3.6.
Does anybody know a good instruction website for building gradle projects (other than Getting started with Gradle)? I've also re-setup the project based on these instructions, but I cannot resolve any dependencies either. (auto-import enabled and using a Gradle wrapper)