2022-04-22 05:47:42 +00:00
|
|
|
plugins {
|
|
|
|
id 'java'
|
|
|
|
id 'java-library'
|
|
|
|
id 'maven-publish'
|
|
|
|
id 'signing'
|
|
|
|
}
|
2023-06-15 03:31:07 +00:00
|
|
|
|
|
|
|
apply from: '../spotless.gradle'
|
|
|
|
|
2022-05-26 07:33:04 +00:00
|
|
|
group "org.bdware.bdcontract"
|
2024-06-20 03:19:22 +00:00
|
|
|
version "0.7.5"
|
2022-04-22 05:47:42 +00:00
|
|
|
sourceCompatibility = 1.8
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
mavenLocal()
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2023-04-07 12:25:30 +00:00
|
|
|
implementation 'com.google.code.gson:gson:2.9.1'
|
|
|
|
implementation project(":gmhelper")
|
|
|
|
implementation project(":sdk-java")
|
2022-04-22 05:47:42 +00:00
|
|
|
implementation 'org.bouncycastle:bcpkix-jdk15on:1.69'
|
|
|
|
implementation 'org.bouncycastle:bcprov-jdk15on:1.69'
|
|
|
|
implementation 'org.apache.httpcomponents:httpclient:4.5.13'
|
|
|
|
implementation 'org.apache.httpcomponents:httpmime:4.5.13'
|
2024-06-20 03:19:22 +00:00
|
|
|
implementation 'org.bdware.doip:bdosclient:0.0.8'
|
2023-04-20 03:48:22 +00:00
|
|
|
// implementation 'org.bdware.doip:doip-audit-tool:1.2.4'
|
2022-04-22 05:47:42 +00:00
|
|
|
testImplementation 'junit:junit:4.13.2'
|
|
|
|
}
|
|
|
|
|
2022-05-26 07:33:04 +00:00
|
|
|
task copyLibs(type: Copy, dependsOn: [':ypk-deploy-tool:jar']) {
|
|
|
|
from configurations.runtimeClasspath
|
|
|
|
into "./build/output/libs/"
|
|
|
|
}
|
|
|
|
task copyScript(type: Copy) {
|
|
|
|
from "./docker/javarun.sh"
|
|
|
|
from "./docker/docker-compose/deployentry.json"
|
|
|
|
into "./build/output/"
|
|
|
|
}
|
2022-06-30 02:58:59 +00:00
|
|
|
task copyJar(type: Copy, dependsOn: [":ypk-deploy-tool:copyLibs", ":ypk-deploy-tool:copyScript"]) {
|
2022-05-26 07:33:04 +00:00
|
|
|
from "./build/libs/$project.name-${project.version}.jar"
|
|
|
|
into "./build/output"
|
|
|
|
rename { String fileName -> "${project.name}.jar" }
|
|
|
|
doFirst {
|
|
|
|
println "copyJar start"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2022-04-22 05:47:42 +00:00
|
|
|
task classJar(type: Jar, dependsOn: classes) {
|
|
|
|
classifier = "jar"
|
|
|
|
}
|
|
|
|
task sourceJar(type: Jar, dependsOn: classes) {
|
|
|
|
archiveClassifier = "sources"
|
|
|
|
classifier = "sources"
|
|
|
|
from sourceSets.main.allSource
|
|
|
|
}
|
|
|
|
|
|
|
|
tasks.withType(Javadoc) {
|
|
|
|
options.addStringOption('Xdoclint:none', '-quiet')
|
|
|
|
}
|
|
|
|
|
|
|
|
task javadocJar(type: Jar, dependsOn: javadoc) {
|
|
|
|
archiveClassifier = 'javadoc'
|
|
|
|
classifier = "javadoc"
|
|
|
|
exclude {
|
|
|
|
details -> details.file.getAbsolutePath().contains("/gm/")
|
|
|
|
}
|
|
|
|
from javadoc.destinationDir
|
|
|
|
}
|
|
|
|
|
|
|
|
publishing {
|
|
|
|
publications {
|
|
|
|
mavenJava(MavenPublication) {
|
|
|
|
groupId project.group
|
|
|
|
artifactId "ypk-deploy-tool"
|
|
|
|
version "${version}"
|
|
|
|
from components.java
|
|
|
|
artifact sourceJar
|
|
|
|
artifact javadocJar
|
|
|
|
artifact classJar
|
|
|
|
pom {
|
|
|
|
name = "bdware-ypk-deploy-tool"
|
|
|
|
description = "ypk-deploy-tool"
|
|
|
|
url = "https://gitee.com/BDWare/ypk-deploy-tool"
|
|
|
|
licenses {
|
|
|
|
license {
|
|
|
|
name = "Mulan PSL v2"
|
|
|
|
url = "http://license.coscl.org.cn/MulanPSL2"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
developers {
|
|
|
|
developer {
|
|
|
|
id = "dataware"
|
|
|
|
email = "caihq@pku.edu.cn"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
scm {
|
|
|
|
connection = "scm:git:https://gitee.com/BDWare/ypk-deploy-tool.git"
|
|
|
|
developerConnection = "scm:git:https://gitee.com/BDWare/ypk-deploy-tool.git"
|
|
|
|
url = "https://gitee.com/BDWare/ypk-deploy-tool"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
repositories {
|
|
|
|
maven {
|
|
|
|
name 'bdwareSnapshotRepository'
|
|
|
|
url 'https://oss.sonatype.org/content/repositories/snapshots'
|
|
|
|
credentials {
|
|
|
|
username = "${NEXUS_USERNAME}"
|
|
|
|
password = "${NEXUS_PASSWORD}"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
maven {
|
|
|
|
name 'bdwareRepository'
|
|
|
|
url 'https://oss.sonatype.org/service/local/staging/deploy/maven2'
|
|
|
|
credentials {
|
|
|
|
username = "${NEXUS_USERNAME}"
|
|
|
|
password = "${NEXUS_PASSWORD}"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
signing {
|
|
|
|
sign publishing.publications.mavenJava
|
|
|
|
}
|