Add provided dependencies to classpath of androidJavadocs
jfresen opened this issue · 4 comments
I'm using provided dependencies in my library project, which works fine but for one issue. When the uploadArchives task executes the androidJavadocs task, it gives compiler errors (interpreted by androidJavadocs as warnings) for all references to the provided dependencies. Is there a way in which I can add the provided dependencies to the classpath of androidJavadocs?
+1
I encountered the same problem.
It looks that path needs to be appended here: https://github.com/chrisbanes/gradle-mvn-push/blob/master/gradle-mvn-push.gradle#L97
If you are using
apply from: 'https://raw.github.com/chrisbanes/gradle-mvn-push/master/gradle-mvn-push.gradle'
that snippet should do the trick:
afterEvaluate { project ->
android.libraryVariants.all { variant ->
tasks.androidJavadocs.doFirst {
classpath += files(variant.javaCompile.classpath.files)
}
}
}
@jfresen I meet the error :Could not get unknown property 'android' for task ':androidJavadocs' Did you solve your problem?
I have fixed it in my library using: drakeet/MultiType@ef940c0
Maybe I could create a PR for the project? @chrisbanes