Merge commit 'refs/pull/10/head' of github.com:bitcoindevkit/bdk-kotlin
This commit is contained in:
commit
9e35866a47
@ -1,94 +0,0 @@
|
||||
apply plugin: 'com.android.library'
|
||||
apply plugin: 'kotlin-android'
|
||||
apply plugin: 'maven-publish'
|
||||
apply plugin: 'signing'
|
||||
|
||||
android {
|
||||
compileSdkVersion 31
|
||||
|
||||
defaultConfig {
|
||||
minSdkVersion 21
|
||||
targetSdkVersion 31
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
consumerProguardFiles 'consumer-rules.pro'
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation 'net.java.dev.jna:jna:5.8.0@aar'
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
||||
implementation 'androidx.appcompat:appcompat:1.4.0'
|
||||
implementation 'androidx.core:core-ktx:1.7.0'
|
||||
api "org.slf4j:slf4j-api:1.7.30"
|
||||
|
||||
androidTestImplementation 'com.github.tony19:logback-android:2.0.0'
|
||||
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
|
||||
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
|
||||
androidTestImplementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.4.1'
|
||||
}
|
||||
|
||||
afterEvaluate {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
// Creates a Maven publication called "release".
|
||||
release(MavenPublication) {
|
||||
// Applies the component for the release build variant.
|
||||
from components.release
|
||||
|
||||
// You can then customize attributes of the publication as shown below.
|
||||
groupId = 'org.bitcoindevkit'
|
||||
artifactId = 'bdk-android'
|
||||
version = '0.3.2'
|
||||
|
||||
pom {
|
||||
name = 'bdk-android'
|
||||
description = 'Bitcoin Dev Kit Kotlin language bindings.'
|
||||
url = "https://bitcoindevkit.org"
|
||||
licenses {
|
||||
license {
|
||||
name = "APACHE"
|
||||
url = "https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-APACHE"
|
||||
}
|
||||
license {
|
||||
name = "MIT"
|
||||
url = "https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-MIT"
|
||||
}
|
||||
}
|
||||
developers {
|
||||
developer {
|
||||
id = 'notmandatory'
|
||||
name = 'Steve Myers'
|
||||
email = 'notmandatory@noreply.github.org'
|
||||
}
|
||||
developer {
|
||||
id = 'artfuldev'
|
||||
name = 'Sudarsan Balaji'
|
||||
email = 'sudarsan.balaji@artfuldev.com'
|
||||
}
|
||||
}
|
||||
scm {
|
||||
connection = 'scm:git:github.com/bitcoindevkit/bdk-ffi.git'
|
||||
developerConnection = 'scm:git:ssh://github.com/bitcoindevkit/bdk-ffi.git'
|
||||
url = 'https://github.com/bitcoindevkit/bdk-ffi/tree/master'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
signing {
|
||||
useGpgCmd()
|
||||
sign publishing.publications
|
||||
}
|
89
android/build.gradle.kts
Normal file
89
android/build.gradle.kts
Normal file
@ -0,0 +1,89 @@
|
||||
plugins {
|
||||
id("com.android.library")
|
||||
id("kotlin-android")
|
||||
id("maven-publish")
|
||||
id("signing")
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdk = 31
|
||||
|
||||
defaultConfig {
|
||||
minSdk = 21
|
||||
targetSdk = 31
|
||||
// versionCode = 1
|
||||
// versionName = "v0.2.2"
|
||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||
consumerProguardFiles("consumer-rules.pro")
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
getByName("release") {
|
||||
isMinifyEnabled = false
|
||||
proguardFiles(file("proguard-android-optimize.txt"), file("proguard-rules.pro"))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation("net.java.dev.jna:jna:5.8.0@aar")
|
||||
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk7")
|
||||
implementation("androidx.appcompat:appcompat:1.4.0")
|
||||
implementation("androidx.core:core-ktx:1.7.0")
|
||||
api("org.slf4j:slf4j-api:1.7.30")
|
||||
|
||||
androidTestImplementation("com.github.tony19:logback-android:2.0.0")
|
||||
androidTestImplementation("androidx.test.ext:junit:1.1.3")
|
||||
androidTestImplementation("androidx.test.espresso:espresso-core:3.4.0")
|
||||
androidTestImplementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.4.1")
|
||||
}
|
||||
|
||||
afterEvaluate {
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("maven") {
|
||||
groupId = "org.bitcoindevkit"
|
||||
artifactId = "bdk-android"
|
||||
version = "0.3.2"
|
||||
from(components["release"])
|
||||
pom {
|
||||
name.set("bdk-android")
|
||||
description.set("Bitcoin Dev Kit Kotlin language bindings.")
|
||||
url.set("https://bitcoindevkit.org")
|
||||
licenses {
|
||||
license {
|
||||
name.set("APACHE 2.0")
|
||||
url.set("https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-APACHE")
|
||||
}
|
||||
license {
|
||||
name.set("MIT")
|
||||
url.set("https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-MIT")
|
||||
}
|
||||
}
|
||||
developers {
|
||||
developer {
|
||||
id.set("notmandatory")
|
||||
name.set("Steve Myers")
|
||||
email.set("notmandatory@noreply.github.org")
|
||||
}
|
||||
developer {
|
||||
id.set("artfuldev")
|
||||
name.set("Sudarsan Balaji")
|
||||
email.set("sudarsan.balaji@artfuldev.com")
|
||||
}
|
||||
}
|
||||
scm {
|
||||
connection.set("scm:git:github.com/bitcoindevkit/bdk-ffi.git")
|
||||
developerConnection.set("scm:git:ssh://github.com/bitcoindevkit/bdk-ffi.git")
|
||||
url.set("https://github.com/bitcoindevkit/bdk-ffi/tree/master")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
signing {
|
||||
useGpgCmd()
|
||||
sign(publishing.publications)
|
||||
}
|
51
build.gradle
51
build.gradle
@ -1,51 +0,0 @@
|
||||
buildscript {
|
||||
ext.kotlin_version = '1.6.10'
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:7.0.4'
|
||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||
}
|
||||
}
|
||||
|
||||
plugins {
|
||||
id "signing"
|
||||
id "maven-publish"
|
||||
id "io.github.gradle-nexus.publish-plugin" version "1.1.0"
|
||||
}
|
||||
|
||||
signing {
|
||||
def signingKey = findProperty("signingKey")
|
||||
def signingPassword = findProperty("signingPassword")
|
||||
useInMemoryPgpKeys(signingKey, signingPassword)
|
||||
sign publishing.publications
|
||||
}
|
||||
|
||||
nexusPublishing {
|
||||
packageGroup = "org.bitcoindevkit"
|
||||
repositories {
|
||||
sonatype {
|
||||
nexusUrl.set(uri("https://s01.oss.sonatype.org/service/local/"))
|
||||
snapshotRepositoryUrl.set(uri("https://s01.oss.sonatype.org/content/repositories/snapshots/"))
|
||||
|
||||
username = project.findProperty("ossrhUsername")
|
||||
password = project.findProperty("ossrhPassword")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
allprojects {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
|
||||
kotlinOptions {
|
||||
freeCompilerArgs += [
|
||||
"-Xopt-in=kotlin.ExperimentalUnsignedTypes",
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
52
build.gradle.kts
Normal file
52
build.gradle.kts
Normal file
@ -0,0 +1,52 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath("com.android.tools.build:gradle:7.0.4")
|
||||
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.10")
|
||||
}
|
||||
}
|
||||
|
||||
plugins {
|
||||
id("signing")
|
||||
id("maven-publish")
|
||||
id("io.github.gradle-nexus.publish-plugin") version "1.1.0"
|
||||
}
|
||||
|
||||
signing {
|
||||
val signingKey: String? by project
|
||||
val signingPassword: String? by project
|
||||
useInMemoryPgpKeys(signingKey, signingPassword)
|
||||
sign(publishing.publications)
|
||||
}
|
||||
|
||||
// does this need to be defined here? Not sure
|
||||
// it used to be defined in the nexusPublishing block but is not required
|
||||
// I think the group ID is defined in the specific publishing blocks in the respective build.gradle.kts
|
||||
group = "org.bitcoindevkit"
|
||||
|
||||
nexusPublishing {
|
||||
repositories {
|
||||
create("sonatype") {
|
||||
nexusUrl.set(uri("https://s01.oss.sonatype.org/service/local/"))
|
||||
snapshotRepositoryUrl.set(uri("https://s01.oss.sonatype.org/content/repositories/snapshots/"))
|
||||
|
||||
val ossrhUsername: String? by project
|
||||
val ossrhPassword: String? by project
|
||||
username.set(ossrhUsername)
|
||||
password.set(ossrhPassword)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
allprojects {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
|
||||
kotlinOptions.freeCompilerArgs += "-opt-in=kotlin.ExperimentalUnsignedTypes"
|
||||
}
|
||||
}
|
@ -1,83 +0,0 @@
|
||||
plugins {
|
||||
id 'org.jetbrains.kotlin.jvm'
|
||||
id 'java-library'
|
||||
id 'maven-publish'
|
||||
id 'signing'
|
||||
}
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
|
||||
withJavadocJar()
|
||||
withSourcesJar()
|
||||
}
|
||||
|
||||
test {
|
||||
testLogging {
|
||||
events "PASSED", "SKIPPED", "FAILED", "STANDARD_OUT", "STANDARD_ERROR"
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation platform('org.jetbrains.kotlin:kotlin-bom')
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
||||
implementation "net.java.dev.jna:jna:5.8.0"
|
||||
api "org.slf4j:slf4j-api:1.7.30"
|
||||
testImplementation "junit:junit:4.13.2"
|
||||
testImplementation "ch.qos.logback:logback-classic:1.2.3"
|
||||
testImplementation "ch.qos.logback:logback-core:1.2.3"
|
||||
}
|
||||
|
||||
afterEvaluate {
|
||||
publishing {
|
||||
publications {
|
||||
|
||||
release(MavenPublication) {
|
||||
from components.java
|
||||
|
||||
groupId = 'org.bitcoindevkit'
|
||||
artifactId = 'bdk-jvm'
|
||||
version = '0.3.2'
|
||||
|
||||
pom {
|
||||
name = 'bdk-jvm'
|
||||
description = 'Bitcoin Dev Kit Kotlin language bindings.'
|
||||
url = "https://bitcoindevkit.org"
|
||||
licenses {
|
||||
license {
|
||||
name = "APACHE"
|
||||
url = "https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-APACHE"
|
||||
}
|
||||
license {
|
||||
name = "MIT"
|
||||
url = "https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-MIT"
|
||||
}
|
||||
}
|
||||
developers {
|
||||
developer {
|
||||
id = 'notmandatory'
|
||||
name = 'Steve Myers'
|
||||
email = 'notmandatory@noreply.github.org'
|
||||
}
|
||||
developer {
|
||||
id = 'artfuldev'
|
||||
name = 'Sudarsan Balaji'
|
||||
email = 'sudarsan.balaji@artfuldev.com'
|
||||
}
|
||||
}
|
||||
scm {
|
||||
connection = 'scm:git:github.com/bitcoindevkit/bdk-ffi.git'
|
||||
developerConnection = 'scm:git:ssh://github.com/bitcoindevkit/bdk-ffi.git'
|
||||
url = 'https://github.com/bitcoindevkit/bdk-ffi/tree/master'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
signing {
|
||||
useGpgCmd()
|
||||
sign publishing.publications
|
||||
}
|
91
jvm/build.gradle.kts
Normal file
91
jvm/build.gradle.kts
Normal file
@ -0,0 +1,91 @@
|
||||
import org.gradle.api.tasks.testing.logging.TestExceptionFormat.*
|
||||
import org.gradle.api.tasks.testing.logging.TestLogEvent.*
|
||||
|
||||
plugins {
|
||||
id("org.jetbrains.kotlin.jvm")
|
||||
id("java-library")
|
||||
id("maven-publish")
|
||||
id("signing")
|
||||
}
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
withSourcesJar()
|
||||
}
|
||||
|
||||
tasks.withType<Test> {
|
||||
useJUnitPlatform()
|
||||
|
||||
testLogging {
|
||||
events(PASSED, SKIPPED, FAILED, STANDARD_OUT, STANDARD_ERROR)
|
||||
exceptionFormat = FULL
|
||||
showExceptions = true
|
||||
showCauses = true
|
||||
showStackTraces = true
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(platform("org.jetbrains.kotlin:kotlin-bom"))
|
||||
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk7")
|
||||
implementation("net.java.dev.jna:jna:5.8.0")
|
||||
api("org.slf4j:slf4j-api:1.7.30")
|
||||
testImplementation("junit:junit:4.13.2")
|
||||
testRuntimeOnly("org.junit.vintage:junit-vintage-engine:5.8.2")
|
||||
testImplementation("ch.qos.logback:logback-classic:1.2.3")
|
||||
testImplementation("ch.qos.logback:logback-core:1.2.3")
|
||||
}
|
||||
|
||||
afterEvaluate {
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("maven") {
|
||||
|
||||
groupId = "org.bitcoindevkit"
|
||||
artifactId = "bdk-jvm"
|
||||
version = "0.3.2"
|
||||
|
||||
from(components["java"])
|
||||
|
||||
pom {
|
||||
name.set("bdk-jvm")
|
||||
description.set("Bitcoin Dev Kit Kotlin language bindings.")
|
||||
url.set("https://bitcoindevkit.org")
|
||||
licenses {
|
||||
license {
|
||||
name.set("APACHE 2.0")
|
||||
url.set("https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-APACHE")
|
||||
}
|
||||
license {
|
||||
name.set("MIT")
|
||||
url.set("https://github.com/bitcoindevkit/bdk/blob/master/LICENSE-MIT")
|
||||
}
|
||||
}
|
||||
developers {
|
||||
developer {
|
||||
id.set("notmandatory")
|
||||
name.set("Steve Myers")
|
||||
email.set("notmandatory@noreply.github.org")
|
||||
}
|
||||
developer {
|
||||
id.set("artfuldev")
|
||||
name.set("Sudarsan Balaji")
|
||||
email.set("sudarsan.balaji@artfuldev.com")
|
||||
}
|
||||
}
|
||||
scm {
|
||||
connection.set("scm:git:github.com/bitcoindevkit/bdk-ffi.git")
|
||||
developerConnection.set("scm:git:ssh://github.com/bitcoindevkit/bdk-ffi.git")
|
||||
url.set("https://github.com/bitcoindevkit/bdk-ffi/tree/master")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
signing {
|
||||
useGpgCmd()
|
||||
sign(publishing.publications)
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user