I have published a library to Bintray and I have been notified that it was correctly linked to JCenter. The library in Bintray can be seen here and just to be sure, it is correctly visible in JCenter as you can see here.
I am trying to test it by adding it as a Gradle dependency like this:
dependencies {
compile 'com.truizlop.sectionedrecyclerview:library:1.0.0'
}
Which should be correct according to the maven-metadata.xml
file:
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<groupId>com.truizlop.sectionedrecyclerview</groupId>
<artifactId>library</artifactId>
<version>1.0.0</version>
<versioning>
<latest>1.0.0</latest>
<release>1.0.0</release>
<versions>
<version>1.0.0</version>
</versions>
<lastUpdated>20150717035732</lastUpdated>
</versioning>
</metadata>
However, when I sync the build.gradle
it throws the following error:
Failed to resolve: com.truizlop.sectionedrecyclerview:library:1.0.0
I have checked that I am able to sync any other dependencies in JCenter, but I cannot do it with my own library. The library has not been sent to Maven Central, but I think that shouldn't be a problem since JCenter is the default repository for Android Studio. What am I missing?
When I run gradle assembleDebug
from the command line, for a project created with the new project wizard and adding your dependency, I get:
inconsistent module metadata found. Descriptor:
com.truizlop.sectionedrecyclerview:sectionedRecyclerView:1.0.0 Errors: bad module name:
expected='library' found='sectionedRecyclerView'
Your POM has <artifactId>sectionedRecyclerView</artifactId>
, which does not match where the artifact is uploaded or your maven-metadata.xml
file.