android photoview github,android - Not able to resolve com.github.chrisbanes:PhotoView:1.3.1 - Stack...

I had this issue and solved this by adding the repository in buildscript. Here you can see my build.gradle (not the module, but the project one) :

// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {

repositories {

maven { url "https://jitpack.io" }

}

dependencies {

classpath 'com.android.tools.build:gradle:2.2.3'

// NOTE: Do not place your application dependencies here; they belong

// in the individual module build.gradle files

}

}

allprojects {

repositories {

maven { url "https://jitpack.io" }

}

}

task clean(type: Delete) {

delete rootProject.buildDir

}

I don't know why I needed to do that because one my friend just added the repository in the allprojects block and it works for him.

你可能感兴趣的:(android,photoview,github)