Skip to content

Commit

Permalink
Update MavenCentral script
Browse files Browse the repository at this point in the history
  • Loading branch information
akexorcist committed Apr 13, 2021
1 parent 81e36f9 commit 4afb22f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 11 deletions.
2 changes: 0 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ buildscript {
dependencies {
classpath 'com.android.tools.build:gradle:4.1.3'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$project.kotlin_version"
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4'
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
classpath "org.jetbrains.dokka:dokka-android-gradle-plugin:0.9.17"
}
}
Expand Down
13 changes: 5 additions & 8 deletions publish/mavencentral.gradle
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
apply plugin: 'maven-publish'
apply plugin: 'signing'
apply plugin: 'org.jetbrains.dokka-android'

task dokkaJavadoc(type: org.jetbrains.dokka.gradle.DokkaTask) {
outputFormat = 'javadoc'
outputDirectory = "$buildDir/documentation"

task androidJavadocJar(type: Jar) {
archiveClassifier.set('javadoc')
from("$buildDir/javadoc")
}

task androidSourcesJar(type: Jar) {
Expand All @@ -18,10 +18,6 @@ task androidSourcesJar(type: Jar) {
}
}

artifacts {
archives [androidSourcesJar, dokkaJavadoc]
}

group = project.groupId
version = project.versionName

Expand Down Expand Up @@ -61,6 +57,7 @@ publishing {
artifact("$buildDir/libs/${project.getName()}-${version}.jar")
}

artifact androidJavadocJar
artifact androidSourcesJar

pom {
Expand Down
11 changes: 10 additions & 1 deletion round-corner-progress-bar/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'org.jetbrains.dokka-android'

android {
compileSdkVersion project.compileSdkVersion
Expand All @@ -21,15 +23,22 @@ android {
main {
manifest.srcFile 'src/main/AndroidManifest.xml'
java.srcDirs = ['src/main/java']
res.srcDirs = ['src/main/res']
}
}
}

task dokkaJavadoc(type: org.jetbrains.dokka.gradle.DokkaTask) {
outputFormat = 'javadoc'
outputDirectory = "$buildDir/javadoc"
}

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
testImplementation 'junit:junit:4.13.2'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation "androidx.annotation:annotation:1.2.0"
implementation "androidx.customview:customview:1.1.0"
testImplementation 'junit:junit:4.13.2'
}

//apply from: '../publish/mavencentral.gradle'

0 comments on commit 4afb22f

Please sign in to comment.