I am trying to build u202 android project by Jake Wharton. My android studio is failing to build the project. The error being shown is as below:
Gradle 2.1 is r
Go to Settings -> Gradle
and click Use default gradle wrapper (recommended)
. Press Apply
.
After that go to project-dir/gradle/wrapper/gradle-wrapper.properties
and change distributionUrl
like so:
distributionUrl=https\://services.gradle.org/distributions/gradle-2.1-all.zip
Try to Build -> Make Project
.
You also may need to make sure that all components (Android Studio, Gradle itself and Android Gradle plugin) can be used together. Check out this page, here we can see that Gradle 2.1 can be used on Android Studio 0.9.0 - 0.9.3 and Gradle plugin has to be of version 0.14.0 - 0.14.4.