|
|
@ -1,13 +1,13 @@ |
|
|
|
import cash.z.ecc.android.Deps |
|
|
|
|
|
|
|
plugins { |
|
|
|
id 'maven-publish' |
|
|
|
id 'com.jfrog.bintray' |
|
|
|
id "org.jetbrains.kotlin.jvm" |
|
|
|
id 'org.jetbrains.dokka' version '0.10.1' |
|
|
|
id 'java-library' |
|
|
|
} |
|
|
|
|
|
|
|
group = "cash.z.ecc.android" |
|
|
|
version = "1.0.0-beta01" |
|
|
|
|
|
|
|
tasks { |
|
|
|
compileKotlin { |
|
|
|
kotlinOptions { jvmTarget = 1.8 } |
|
|
@ -17,6 +17,11 @@ tasks { |
|
|
|
kotlinOptions { jvmTarget = 1.8 } |
|
|
|
sourceCompatibility = 1.8 |
|
|
|
} |
|
|
|
|
|
|
|
// Generate Kotlin/Java documentation from sources. |
|
|
|
dokka { |
|
|
|
outputFormat = "html" |
|
|
|
} |
|
|
|
} |
|
|
|
dependencies { |
|
|
|
implementation Deps.Kotlin.STDLIB |
|
|
@ -42,3 +47,104 @@ test { |
|
|
|
|
|
|
|
sourceCompatibility = "8" |
|
|
|
targetCompatibility = "8" |
|
|
|
|
|
|
|
|
|
|
|
///////////////////////////////////////// |
|
|
|
// Publishing |
|
|
|
///////////////////////////////////////// |
|
|
|
|
|
|
|
group = Deps.group |
|
|
|
version = Deps.versionName |
|
|
|
|
|
|
|
// Create the pom configuration: |
|
|
|
def pomConfig = { |
|
|
|
licenses { |
|
|
|
license { |
|
|
|
name "MIT-style" |
|
|
|
url "http://opensource.org/licenses/MIT" |
|
|
|
distribution "repo" |
|
|
|
} |
|
|
|
} |
|
|
|
developers { |
|
|
|
developer { |
|
|
|
id "gmale" |
|
|
|
name "Kevin Gorham" |
|
|
|
email "kevin.gorham@z.cash" |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
scm { |
|
|
|
url "https://github.com/zcash/android-bip39" |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// Jar containing Kotlin sources |
|
|
|
task sourcesJar(type: Jar) { |
|
|
|
archiveClassifier = 'sources' |
|
|
|
from kotlin.sourceSets.main.kotlin.srcDirs |
|
|
|
} |
|
|
|
|
|
|
|
// Jar containing docs |
|
|
|
task docsJar(type: Jar) { |
|
|
|
archiveClassifier = "javadoc" |
|
|
|
group = JavaBasePlugin.DOCUMENTATION_GROUP |
|
|
|
dependsOn dokka |
|
|
|
from dokka |
|
|
|
} |
|
|
|
|
|
|
|
task javadocJar(type: Jar, dependsOn: javadoc) { |
|
|
|
archiveClassifier = 'javadoc' |
|
|
|
from javadoc.destinationDir |
|
|
|
} |
|
|
|
|
|
|
|
artifacts { |
|
|
|
archives sourcesJar |
|
|
|
archives docsJar |
|
|
|
} |
|
|
|
|
|
|
|
publishing { |
|
|
|
publications { |
|
|
|
Production(MavenPublication) { |
|
|
|
from components.java |
|
|
|
artifact sourcesJar |
|
|
|
artifact docsJar |
|
|
|
groupId Deps.group |
|
|
|
artifactId "android-bip39" |
|
|
|
version Deps.versionName |
|
|
|
|
|
|
|
pom.withXml { |
|
|
|
def root = asNode() |
|
|
|
root.appendNode('description', Deps.description) |
|
|
|
root.appendNode('name', 'android-bip39') |
|
|
|
root.appendNode('url', 'https://github.com/zcash/android-bip39') |
|
|
|
root.children().last() + pomConfig |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
bintray { |
|
|
|
user = project.hasProperty('bintrayUser') ?: System.getenv('BINTRAY_USER') |
|
|
|
key = project.hasProperty('bintrayApiKey') ?: System.getenv('BINTRAY_API_KEY') |
|
|
|
publications = ['Production'] |
|
|
|
configurations = ['archives'] |
|
|
|
override = true |
|
|
|
pkg { |
|
|
|
repo = 'android-bip39' |
|
|
|
name = 'android-bip39' |
|
|
|
description = Deps.description |
|
|
|
publish = true |
|
|
|
publicDownloadNumbers = true |
|
|
|
userOrg = 'ecc-mobile' |
|
|
|
licenses = ['MIT'] |
|
|
|
vcsUrl = 'https://github.com/zcash/android-bip39.git' |
|
|
|
dryRun = false |
|
|
|
version { |
|
|
|
name = Deps.versionName |
|
|
|
desc = "v${this.version}" |
|
|
|
released = new Date() |
|
|
|
vcsTag = this.version |
|
|
|
} |
|
|
|
} |
|
|
|
} |