forked from AfterShip/aftership-sdk-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
publishing.gradle
57 lines (52 loc) · 1.9 KB
/
publishing.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
apply plugin: 'maven-publish'
apply plugin: 'signing'
def publishConfigFilePath = rootDir.canonicalPath + '/.gradle/publish.gradle'
if (file("${publishConfigFilePath}").exists()) {
apply from: "${publishConfigFilePath}"
publishing {
publications {
mavenJava(MavenPublication) {
groupId = 'com.aftership'
artifactId = 'aftership-sdk'
version = project.version
from components.java
artifact sourcesJar
artifact javadocJar
pom {
name = 'aftership-sdk'
description = 'aftership-sdk library'
url = 'https://docs.aftership.com/api/4/overview'
licenses {
license {
name = 'MIT License'
url = 'https://opensource.org/licenses/MIT'
}
}
developers {
developer {
name = 'chenjunbiao'
email = '[email protected]'
}
}
scm {
url = 'https://github.com/AfterShip/aftership-sdk-java.git'
connection = 'scm:git:[email protected]:AfterShip/aftership-sdk-java.git'
developerConnection = 'scm:git:ssh://[email protected]:AfterShip/aftership-sdk-java.git'
}
}
}
}
repositories {
maven {
url "https://oss.sonatype.org/service/local/staging/deploy/maven2"
credentials {
username sonatypeUsername
password sonatypePassword
}
}
}
}
signing {
sign publishing.publications.mavenJava
}
}