Subby
Subby

Reputation: 5480

Android Studio could not find any version that matches gradle

Recently, I have been doing a major refactor in my project where I have built a new project and started to move classes and methods from one project to the other. Along the way, I must have done something wrong that's messed up my project.

When I try to sync/build the project, I get:

Error:

Could not find any version that matches com.android.tools.build:gradle:0.11.+.
Required by:
    android_app:appName:unspecified

Gradle:

buildscript {
    dependencies {
        classpath 'com.android.tools.build:gradle:0.11.+'
    }
}
apply plugin: 'android'

android {
    compileSdkVersion 19
    buildToolsVersion "19.1.0"
    lintOptions {
        abortOnError false
    }
    defaultConfig {
        minSdkVersion 11
        targetSdkVersion 19
    }
    signingConfigs {
    }
    buildTypes {
        release {
            signingConfig signingConfigs.release
        }
    }
    productFlavors {
    }
}
dependencies {
    compile 'com.android.support:support-v4:19.1.+'
    compile 'com.google.maps.android:android-maps-utils:+'
    compile project(':libraries:facebook')
    compile 'com.google.android.gms:play-services:4.+'
    compile files('libs/YouTubeAndroidPlayerApi.jar')
    compile files('libs/libGoogleAnalyticsServices.jar')
    compile files('libs/svg-android.jar')
    compile project(':MyLibrary')
}

Any ideas?

Upvotes: 2

Views: 4502

Answers (1)

ligi
ligi

Reputation: 39539

you need to add repositories:

buildscript {

    repositories {
        jcenter()
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:0.11.+'
    }
}

Upvotes: 1

Related Questions