Skip to content

Commit

Permalink
Added Dokka plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
francoiscampbell committed Feb 5, 2016
1 parent 19140b7 commit 50d8eb9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ buildscript {
dependencies {
classpath 'com.android.tools.build:gradle:2.0.0-alpha7'
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.0.0-rc-1036'
classpath "org.jetbrains.dokka:dokka-gradle-plugin:0.9.6"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
Expand Down
17 changes: 12 additions & 5 deletions circlelayout/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apply plugin: 'com.android.library'
apply plugin: 'com.github.dcendents.android-maven'
apply plugin: 'com.jfrog.bintray'
apply plugin: 'kotlin-android'
apply plugin: 'org.jetbrains.dokka'

def githubUrl = 'https://github.com/francoiscampbell/CircleLayout'
def gitUrl = "${githubUrl}.git"
Expand Down Expand Up @@ -61,14 +62,20 @@ task sourcesJar(type: Jar) {
classifier = 'sources'
}

task javadoc(type: Javadoc) {
source = android.sourceSets.main.java.srcDirs
classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
//for dokka
//noinspection GroovyAssignabilityCheck
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}

task javadocJar(type: Jar, dependsOn: javadoc) {
dokka {
outputFormat = 'javadoc'
outputDirectory = "$buildDir/javadoc"
}

task javadocJar(type: Jar, dependsOn: dokka) {
classifier = 'javadoc'
from javadoc.destinationDir
from dokka.outputDirectory
}

artifacts {
Expand Down

0 comments on commit 50d8eb9

Please sign in to comment.