Tang Cheng | dc14841 | 2019-07-08 09:15:47 +0800 | [diff] [blame] | 1 | plugins { |
| 2 | id 'java' |
Tang Cheng | 5b48e7b | 2019-07-08 15:56:05 +0800 | [diff] [blame^] | 3 | id 'maven-publish' |
Tang Cheng | dc14841 | 2019-07-08 09:15:47 +0800 | [diff] [blame] | 4 | id 'org.springframework.boot' |
| 5 | id "com.palantir.git-version" |
| 6 | } |
| 7 | |
| 8 | |
| 9 | apply plugin: 'io.spring.dependency-management' |
| 10 | |
Tang Cheng | 5b48e7b | 2019-07-08 15:56:05 +0800 | [diff] [blame^] | 11 | sdkVersion = gitVersion() |
| 12 | |
| 13 | publishing { |
| 14 | publications { |
| 15 | mavenJava(MavenPublication) { |
| 16 | groupId = project.group |
| 17 | artifactId = 'payapi-sdk' |
| 18 | version = sdkVersion |
| 19 | from components.java |
| 20 | } |
| 21 | } |
| 22 | repositories { |
| 23 | maven { |
| 24 | // change URLs to point to your repos, e.g. http://my.org/repo |
| 25 | def releasesRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/" |
| 26 | def snapshotsRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/snapshot/" |
| 27 | url = version.endsWith('dirty') ? snapshotsRepoUrl : releasesRepoUrl |
| 28 | credentials(PasswordCredentials) { |
| 29 | username = nxUser |
| 30 | password = nxPassword |
| 31 | } |
| 32 | } |
| 33 | } |
| 34 | } |
| 35 | |
| 36 | jar { |
| 37 | manifest { |
| 38 | attributes('Payapi-SDK-Version': sdkVersion) |
| 39 | } |
| 40 | } |
| 41 | |
Tang Cheng | dc14841 | 2019-07-08 09:15:47 +0800 | [diff] [blame] | 42 | dependencies { |
| 43 | implementation 'org.springframework.boot:spring-boot-starter-data-jpa' |
| 44 | implementation 'org.springframework.boot:spring-boot-starter-data-redis' |
| 45 | |
Tang Cheng | 800e49b | 2019-07-08 13:12:50 +0800 | [diff] [blame] | 46 | |
| 47 | implementation project(':common') |
| 48 | |
Tang Cheng | dc14841 | 2019-07-08 09:15:47 +0800 | [diff] [blame] | 49 | implementation 'org.springframework.cloud:spring-cloud-dependencies:Finchley.SR3' |
| 50 | implementation 'org.springframework.cloud:spring-cloud-starter-openfeign:2.1.2.RELEASE' |
Tang Cheng | 5b48e7b | 2019-07-08 15:56:05 +0800 | [diff] [blame^] | 51 | |
| 52 | implementation 'javax.servlet:javax.servlet-api:4.0.1' |
| 53 | |
| 54 | testImplementation 'org.springframework:spring-test' |
| 55 | testImplementation 'org.springframework.boot:spring-boot-test' |
| 56 | testImplementation 'junit:junit:4.12' |
| 57 | testImplementation project(':common') |
| 58 | |
Tang Cheng | dc14841 | 2019-07-08 09:15:47 +0800 | [diff] [blame] | 59 | } |