jitpack.io failed to resolve github repo jitpack.io failed to resolve github repo android android

jitpack.io failed to resolve github repo


For anyone else that made the simple mistake I made:

Ensure you add the maven { url "https://jitpack.io" } under allprojects instead of buildscript.

Project build.gradle file:

buildscript {    repositories {        jcenter()        // DO NOT ADD IT HERE!!!    }    ...}allprojects {    repositories {        mavenLocal()        jcenter()        // ADD IT HERE        maven { url "https://jitpack.io" }    }}

Thanks to Alexander Pacha for pointing that out in a comment above.


After a few attempts and thanks to jitpack support now I can import my library hosted in Github as a Android Gradle dependency.

I will provide a a few very useful links:

How setup your java library

https://jitpack.io/docs/BUILDING/#gradle-projects

How check logs of your dependency in jitpack

https://jitpack.io/com/github/USER/REPO/TAG/build.log

In my case

https://jitpack.io/com/github/rchampa/DropboxHttpConector/1.0.3/build.log


I have several dependencies from Jitpack and I encountered this issue after migrating to Gradle 2.

The solution in my case was to change the version in distributionUrl in gradle-wrapper.properties from 2.10 (which was automatically set by Studio when I accepted updating the wrapper version) to the latest one.