blob: 8f2e1f12dabeb84024e528cd9a63de77002e77a2 [file] [log] [blame]
Xia Kaixiang80f1e9d2020-02-18 17:40:20 +08001plugins {
2 id 'java'
3 id 'maven-publish'
4 id "com.palantir.git-version"
5}
6
7group = rootProject.group
8
9def sdkVersion = gitVersion()
10sourceCompatibility = 1.8
11targetCompatibility = 1.8
12
13publishing {
14 publications {
15 mavenJava(MavenPublication) {
16 groupId = project.group
17 artifactId = 'bus-qrcode'
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
36dependencies {
37 implementation "org.apache.commons:commons-lang3:3.7"
38 implementation 'com.eatthepath:java-otp:0.1.0'
39 implementation 'org.slf4j:slf4j-api:1.7.25'
40 implementation 'commons-codec:commons-codec:1.9'
41 runtime 'org.slf4j:slf4j-parent:1.7.25'
42 runtime 'org.slf4j:slf4j-simple:1.7.25'
43 testImplementation 'junit:junit:4.12'
44}
45
46jar {
47 enabled = true
48 baseName = "bus-qrcode"
49 manifest {
50 attributes('Bus-QRcode-Version': sdkVersion)
51 }
52}
53
54publish.dependsOn(jar)