Added javadocs and sources compilation tasks

This commit is contained in:
Nelson R. Perez 2018-04-30 17:37:03 -05:00
parent 6410c85fd8
commit b8c0ed6163

View file

@ -37,3 +37,23 @@ dependencies {
compile 'com.jakewharton.rxrelay2:rxrelay:2.0.0'
compile 'com.squareup.okhttp3:okhttp:3.5.0'
}
task sourcesJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier = 'sources'
}
task javadoc(type: Javadoc) {
source = android.sourceSets.main.java.srcDirs
classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives javadocJar
archives sourcesJar
}