2019-11-14 17:49:27 +01:00
|
|
|
plugins {
|
2023-04-02 09:17:16 +02:00
|
|
|
alias(libs.plugins.kotlin) apply false
|
|
|
|
alias(libs.plugins.ksp) apply false
|
2023-04-02 09:21:33 +02:00
|
|
|
alias(libs.plugins.serialization)
|
2024-02-17 12:44:50 +01:00
|
|
|
id "org.jlleitschuh.gradle.ktlint" version "12.1.0"
|
2023-04-02 08:48:58 +02:00
|
|
|
id "io.github.gradle-nexus.publish-plugin" version "1.3.0"
|
2023-05-25 22:10:09 +02:00
|
|
|
id 'ru.vyarus.mkdocs' version '3.0.0'
|
2019-11-14 17:49:27 +01:00
|
|
|
}
|
2023-05-25 22:10:09 +02:00
|
|
|
mkdocs.sourcesDir = 'docs'
|
2019-11-14 17:49:27 +01:00
|
|
|
|
|
|
|
ext {
|
2019-11-14 18:34:40 +01:00
|
|
|
SITE_URL = 'https://github.com/wulkanowy/sdk'
|
|
|
|
GIT_URL = 'https://github.com/wulkanowy/sdk.git'
|
|
|
|
|
2019-11-14 17:49:27 +01:00
|
|
|
jspoon = "1.3.2"
|
2024-01-01 23:16:55 +01:00
|
|
|
jsoup = "1.17.2"
|
2024-03-02 11:07:55 +01:00
|
|
|
slf4j = "2.0.12"
|
2022-02-28 20:57:08 +01:00
|
|
|
moshi = "1.13.0"
|
2019-11-14 17:49:27 +01:00
|
|
|
}
|
|
|
|
|
2024-06-12 20:15:49 +02:00
|
|
|
version = "2.7.0-SNAPSHOT"
|
2021-05-01 23:06:13 +02:00
|
|
|
group = "io.github.wulkanowy"
|
|
|
|
|
|
|
|
nexusPublishing {
|
|
|
|
repositories {
|
|
|
|
sonatype {
|
|
|
|
nexusUrl.set(uri("https://s01.oss.sonatype.org/service/local/"))
|
|
|
|
snapshotRepositoryUrl.set(uri("https://s01.oss.sonatype.org/content/repositories/snapshots/"))
|
|
|
|
username = System.getenv("MAVEN_USERNAME")
|
|
|
|
password = System.getenv("MAVEN_PASSWORD")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2019-11-14 11:26:25 +01:00
|
|
|
allprojects {
|
2019-11-14 17:49:27 +01:00
|
|
|
apply plugin: 'java'
|
|
|
|
apply plugin: 'kotlin'
|
2021-05-01 23:06:13 +02:00
|
|
|
apply plugin: 'maven-publish'
|
|
|
|
apply plugin: 'signing'
|
2019-11-17 17:14:24 +01:00
|
|
|
apply plugin: "org.jlleitschuh.gradle.ktlint"
|
2022-07-31 20:27:40 +02:00
|
|
|
apply plugin: 'kotlinx-serialization'
|
2019-12-23 19:19:30 +01:00
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
2023-11-28 22:55:58 +01:00
|
|
|
maven { url "https://s01.oss.sonatype.org/content/repositories/snapshots/" }
|
2019-12-23 19:19:30 +01:00
|
|
|
maven { url "https://jitpack.io" }
|
|
|
|
}
|
2019-11-17 17:14:24 +01:00
|
|
|
|
2020-06-14 23:33:39 +02:00
|
|
|
dependencies {
|
|
|
|
implementation "org.slf4j:slf4j-api:$slf4j"
|
|
|
|
testImplementation "org.slf4j:slf4j-simple:$slf4j"
|
2023-04-02 09:17:16 +02:00
|
|
|
|
|
|
|
implementation platform(libs.okhttp.bom)
|
2020-06-14 23:33:39 +02:00
|
|
|
}
|
|
|
|
|
2021-05-01 23:06:13 +02:00
|
|
|
java {
|
|
|
|
withJavadocJar()
|
|
|
|
withSourcesJar()
|
|
|
|
}
|
|
|
|
|
|
|
|
publishing {
|
|
|
|
publications {
|
|
|
|
sdk(MavenPublication) {
|
|
|
|
from components.java
|
|
|
|
version = rootProject.version
|
|
|
|
|
|
|
|
pom {
|
|
|
|
name = 'VULCAN UONET+ SDK'
|
|
|
|
description = 'Unified way of retrieving data from the UONET+ register through mobile api and scraping api'
|
|
|
|
url = 'https://github.com/wulkanowy/sdk'
|
|
|
|
licenses {
|
|
|
|
license {
|
|
|
|
name = 'The Apache License, Version 2.0'
|
|
|
|
url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
developers {
|
|
|
|
developer {
|
|
|
|
id = 'mklkj'
|
|
|
|
name = 'Mikołaj Pich'
|
|
|
|
email = 'm.pich@outlook.com'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
scm {
|
|
|
|
connection = 'https://github.com/wulkanowy/sdk.git'
|
|
|
|
developerConnection = 'git@github.com:wulkanowy/sdk.git'
|
|
|
|
url = 'https://github.com/wulkanowy/sdk'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-05-01 23:45:11 +02:00
|
|
|
if (System.getenv("MAVEN_SIGNING_KEY")) {
|
|
|
|
signing {
|
|
|
|
def signingKey = System.getenv("MAVEN_SIGNING_KEY") ?: ""
|
|
|
|
def signingPassword = System.getenv("MAVEN_SIGNING_PASSWORD")
|
|
|
|
useInMemoryPgpKeys(new String(signingKey.decodeBase64()), signingPassword)
|
|
|
|
sign publishing.publications.sdk
|
|
|
|
}
|
2021-05-01 23:06:13 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
javadoc {
|
|
|
|
if (JavaVersion.current().isJava9Compatible()) {
|
|
|
|
options.addBooleanOption('html5', true)
|
2019-12-22 17:46:54 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2019-12-23 19:19:30 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
subprojects {
|
|
|
|
apply plugin: 'jacoco'
|
2019-12-22 17:46:54 +01:00
|
|
|
|
2019-11-17 17:14:24 +01:00
|
|
|
ktlint {
|
2023-12-22 13:39:47 +01:00
|
|
|
// additionalEditorconfigFile.set(file(".editorconfig"))
|
2019-11-17 17:14:24 +01:00
|
|
|
disabledRules = [
|
|
|
|
"no-wildcard-imports",
|
|
|
|
"import-ordering",
|
2023-03-01 21:03:21 +01:00
|
|
|
"max-line-length",
|
|
|
|
"multiline-if-else"
|
2019-11-17 17:14:24 +01:00
|
|
|
]
|
2023-03-01 21:03:21 +01:00
|
|
|
filter {
|
|
|
|
exclude { element -> element.file.path.contains("generated/") }
|
|
|
|
}
|
2019-11-17 17:14:24 +01:00
|
|
|
}
|
2019-11-14 17:49:27 +01:00
|
|
|
|
2023-03-01 21:03:21 +01:00
|
|
|
kotlin {
|
|
|
|
jvmToolchain {
|
|
|
|
languageVersion.set(JavaLanguageVersion.of("11"))
|
2019-11-14 17:49:27 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2023-04-02 09:17:16 +02:00
|
|
|
implementation libs.coroutines.core
|
2019-11-14 13:36:46 +01:00
|
|
|
|
2021-09-18 11:12:27 +02:00
|
|
|
implementation "com.squareup.okhttp3:logging-interceptor"
|
2024-03-02 11:07:55 +01:00
|
|
|
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.3"
|
2019-11-14 17:49:27 +01:00
|
|
|
|
2021-02-26 10:43:37 +01:00
|
|
|
testImplementation "junit:junit:4.13.2"
|
2021-09-18 11:12:27 +02:00
|
|
|
testImplementation "com.squareup.okhttp3:mockwebserver"
|
2023-04-02 09:17:16 +02:00
|
|
|
testImplementation libs.retrofit.mock
|
|
|
|
testImplementation libs.coroutines.test
|
2019-11-14 17:49:27 +01:00
|
|
|
}
|
2019-11-14 18:34:40 +01:00
|
|
|
|
2019-11-17 17:14:24 +01:00
|
|
|
jacocoTestReport {
|
|
|
|
reports {
|
2023-04-15 22:12:33 +02:00
|
|
|
xml.getRequired().set(true)
|
2019-11-17 17:14:24 +01:00
|
|
|
}
|
|
|
|
}
|
2021-05-16 21:20:49 +02:00
|
|
|
jacoco {
|
2023-08-24 23:30:56 +02:00
|
|
|
toolVersion "0.8.10"
|
2021-05-16 21:20:49 +02:00
|
|
|
}
|
2019-11-17 17:14:24 +01:00
|
|
|
|
2019-11-17 17:32:58 +01:00
|
|
|
test {
|
|
|
|
testLogging.showStandardStreams = false
|
|
|
|
}
|
|
|
|
|
2019-12-23 19:20:15 +01:00
|
|
|
group = "io.github.wulkanowy.sdk"
|
2018-08-30 17:22:28 +02:00
|
|
|
}
|
2019-12-23 19:20:15 +01:00
|
|
|
|
|
|
|
dependencies {
|
2021-09-28 14:15:12 +02:00
|
|
|
api project(":sdk")
|
2023-04-15 20:50:43 +02:00
|
|
|
api project(":sdk-hebe")
|
2021-09-28 14:15:12 +02:00
|
|
|
api project(":sdk-scrapper")
|
2020-01-10 15:14:46 +01:00
|
|
|
|
2021-09-28 14:15:12 +02:00
|
|
|
api "com.squareup.okhttp3:okhttp"
|
2019-12-23 19:20:15 +01:00
|
|
|
}
|