123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129 |
- /*
- * ********************************************************************************************************************
- *
- * iFHS7.
- * ;BBMBMBMc rZMBMBR BMB
- * MBEr:;PBM, 7MBMMEOBB: BBB RBW
- * XK: BO SB. :SZ MBM. c;; ir BBM :FFr :SSF: ;xBMB:r iuGXv. i:. iF2;
- * DBBM0r. :D S7 ;XMBMB GMBMu. MBM: BMB MBMBBBMBMS WMBMBMBBK MBMBMBM BMBRBMBW .MBMBMBMBB
- * :JMRMMD .. , 1MMRM1; ;MBMBBR: MBM ;MB: BMB: MBM. RMBr sBMH BM0 UMB, BMB. KMBv
- * ;. XOW B1; :uM: 1RE, i .2BMBs rMB. MBO MBO JMB; MBB MBM BBS 7MBMBOBM: MBW :BMc
- * OBRJ.SEE MRDOWOR, 3DE:7OBM . ;BMB RMR7BM BMB MBB. BMB ,BMR .BBZ MMB rMB, BMM rMB7
- * :FBRO0D0 RKXSXPR. JOKOOMPi BMBSSWBMB; BMBB: MBMB0ZMBMS .BMBOXRBMB MBMDE RBM2;SMBM; MBB xBM2
- * iZGE O0SHSPO. uGZ7. sBMBMBDL :BMO OZu:BMBK, rRBMB0; ,EBMB xBMBr:ER. RDU :OO;
- * ,BZ, 1D0 RPSFHXR. xWZ .SMr . .BBB
- * :0BMRDG RESSSKR. 2WOMBW; BMBMR
- * i0BM: SWKHKGO MBDv
- * .UB OOGDM. MK, Copyright (c) 2015-2019. 斯伯坦机器人
- * , XMW ..
- * r All rights reserved.
- *
- * ********************************************************************************************************************
- */
- group rootProject.group
- version rootProject.version
- apply plugin: "kotlin"
- apply plugin: "org.jetbrains.dokka"
- apply plugin: "maven"
- sourceCompatibility = JVM_TARGET
- compileKotlin {
- kotlinOptions.jvmTarget = JVM_TARGET
- }
- compileTestKotlin {
- kotlinOptions.jvmTarget = JVM_TARGET
- }
- dependencies {
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // kotlin 依赖
- compile group: 'org.jetbrains.kotlin', name: 'kotlin-stdlib-jdk8', version: KOTLIN_VERSION
- compile group: 'org.jetbrains.kotlin', name: 'kotlin-reflect', version: KOTLIN_VERSION
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // 单元测试
- // https://mvnrepository.com/artifact/org.testng/testng
- testCompile group: 'org.testng', name: 'testng', version: TESTNG_VERSION
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // http请求
- // https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp
- compile group: 'com.squareup.okhttp3', name: 'okhttp', version: OKHTTP_VERSION
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // JSON解析
- // https://mvnrepository.com/artifact/com.alibaba/fastjson
- compile group: 'com.alibaba', name: 'fastjson', version: FASTJSON_VERSION
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // 文档生成
- dokka {
- jdkVersion = JDK_VERSION
- outputFormat = 'javadoc'
- outputDirectory = "$buildDir/javadoc"
- //sourceDirs = files('src/main/kotlin')
- }
- // 上成上传的文档jar包
- task javadocJar(type: Jar, dependsOn: dokka) {
- classifier = 'javadoc'
- from dokka.outputDirectory
- }
- // 上成上传的文档jar包
- task sourcesJar(type: Jar) {
- classifier = 'sources'
- from sourceSets.main.allSource
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // maven 仓库管理
- // 设置上传的包,默认上传aar与pom
- artifacts {
- // archives javadocJar
- // archives sourcesJar
- }
- uploadArchives {
- repositories {
- mavenDeployer {
- pom.groupId = project.group
- pom.version = project.version
- pom.artifactId = project.name
- pom.project {
- name project.name
- packaging 'jar'
- url SAGA_URL
- description '斯伯坦机器人 Kotlin 基础支持库。'
- licenses {
- license {
- name LICENSE_NAME
- url LICENSE_URL
- }
- }
- developers {
- developer {
- id DEVELOPER_ID
- name DEVELOPER_NAME
- }
- }
- }
- snapshotRepository(url: MAVEN_REPO_SNAPSHOT_URL) {
- authentication(userName: NEXUS_USERNAME, password: NEXUS_PASSWORD)
- }
- repository(url: MAVEN_REPO_RELEASE_URL) {
- authentication(userName: NEXUS_USERNAME, password: NEXUS_PASSWORD)
- }
- }
- }
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // 自动化测试
- test {
- useTestNG()
- }
|