-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpublishing.gradle
83 lines (73 loc) · 2.46 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
import java.text.SimpleDateFormat
Date buildTimeAndDate = new Date()
ext {
buildDate = new SimpleDateFormat('yyyy-MM-dd').format(buildTimeAndDate)
buildTime = new SimpleDateFormat('HH:mm:ss.SSSZ').format(buildTimeAndDate)
}
def projectArtifactId = 'ktor-resilient'
normalization {
runtimeClasspath {
metaInf {
ignoreAttribute("Build-Time")
ignoreAttribute("Build-Date")
}
}
}
jar {
manifest {
attributes(
'Built-By': 'Oleksandr Loushkin',
'Created-By': System.properties['java.version'] + " (" + System.properties['java.vendor'] + " " + System.properties['java.vm.version'] + ")",
'Build-Date': project.buildDate,
'Build-Time': project.buildTime,
'Specification-Title': projectArtifactId,
'Specification-Version': project.version,
'Implementation-Title': projectArtifactId,
'Implementation-Version': project.version,
)
}
}
task sourcesJar(type: Jar) {
from sourceSets.main.allSource
archiveClassifier = 'sources'
}
task javadocJar(type: Jar, dependsOn: javadoc) {
archiveClassifier = 'javadoc'
from javadoc.destinationDir
}
signing {
useGpgCmd()
sign publishing.publications
}
publishing {
publications {
maven(MavenPublication) {
from components.java
pom {
name = 'Ktor resilient'
description = 'Light implementation of the Ktor framework wrapped by Resilience4j'
url = 'https://github.com/laviua/ktor-resilient'
licenses {
license {
name = 'The Apache License, Version 2.0'
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id = 'laviua'
name = 'Oleksandr Loushkin'
email = 'developer@lavi.com.ua'
}
}
scm {
connection = 'scm:git:git://github.com:laviua/ktor-resilient.git'
developerConnection = 'scm:git:ssh://github.com:laviua/ktor-resilient.git'
url = 'https://github.com:laviua/ktor-resilient.git'
}
}
artifact sourcesJar
artifact javadocJar
}
}
}