title: Gradle fails to resolve dependencies in Android Studio
body: <p>Whenever I add a dependency from an remote repository (jcenter) in Android Studio 1.1 (OS X) I get the following error upon syncing Gradle:</p>
  
  <pre><code>Error:(26, 13) Failed to resolve: &lt;packagename:version&gt;
  </code></pre>
  
  <p>My app's build.gradle is as follows:
     apply plugin: 'com.android.application'</p>
  
  <pre><code>android {
  compileSdkVersion 21
  buildToolsVersion "21.1.2"
  
  defaultConfig {
      applicationId "nl.timmevandermeer.cargoapp"
      minSdkVersion 19
      targetSdkVersion 21
      versionCode 1
      versionName "1.0"
  }
      buildTypes {
          release {
              minifyEnabled false
              proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
          }
      }
  }
  
  dependencies {
       compile fileTree(dir: 'libs', include: ['*.jar'])
       compile 'com.android.support:appcompat-v7:21.0.3'
       compile 'com.android.support:support-v4:21.0.3'
       compile 'com.google.android.gms:play-services:6.5.87'
       compile 'org.json:json:20141113'
  }
  </code></pre>
  
  <p>I have tried changing repositories (jcenter(), mavenCentral(), etc.), reinstalling Android Studio, JDK (7 and 8), changing Gradle version and Android SDK version, none of which worked. Upon running ./gradlew build I get:</p>
  
  <pre><code>Could not resolve com.android.tools.build:gradle:1.1.0.
  13:48:04.914 [ERROR] [org.gradle.BuildExceptionReporter]      Required by:
  13:48:04.915 [ERROR] [org.gradle.BuildExceptionReporter]          :CargoApp:unspecified
  13:48:04.932 [ERROR] [org.gradle.BuildExceptionReporter] &gt;
   org.slf4j.spi.LocationAwareLogger.log(Lorg/slf4j/Marker;Ljava/lang/String;ILjava/lang/String;[Ljava/lang/Object;Ljava/lang/Throwable;)V
  </code></pre>
  
  <p>This is an error I get in other cases as well, for example when trying to use Intellij Idea instead of Android Studio. Running the app without the dependency does work though.</p>