-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.gradle
More file actions
95 lines (76 loc) · 2.79 KB
/
Copy pathbuild.gradle
File metadata and controls
95 lines (76 loc) · 2.79 KB
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
84
85
86
87
88
89
90
91
92
93
94
95
apply plugin: 'java'
apply plugin: 'maven-publish'
apply plugin: 'signing'
apply from: "$rootDir/gradle/release.gradle"
sourceCompatibility = 1.8
targetCompatibility = 1.8
repositories {
mavenCentral()
}
dependencies {
compile 'net.openhft:affinity:3.1.13'
compile 'org.slf4j:slf4j-api:1.7.14'
compileOnly 'com.google.code.findbugs:jsr305:3.0.1'
testCompile 'junit:junit:4.+'
}
ext.isReleaseVersion = !version.endsWith("SNAPSHOT")
java {
withJavadocJar()
withSourcesJar()
}
def rUser = findProperty('SONATYPE_NEXUS_USERNAME') ?: System.getenv('SONATYPE_NEXUS_USERNAME') ?: "FakeUser"
def rPass = findProperty('SONATYPE_NEXUS_PASSWORD') ?: System.getenv('SONATYPE_NEXUS_PASSWORD') ?: "FakePass"
publishing {
repositories {
maven {
url = findProperty('SONATYPE_REPOSITORY') ?: System.getenv('SONATYPE_REPOSITORY') ?: "FakeRepo"
credentials {
username rUser
password rPass
}
}
}
publications {
mavenJava(MavenPublication) {
from components.java
pom {
name = 'thread.affinity'
packaging = 'jar'
description = 'A wrapper over net.openhft:affinity providing handy classes to create threads pinned to the specified CPUs.'
url = 'https://github.com/epam/ThreadAffinity'
scm {
connection = 'scm:git:https://github.com/epam/ThreadAffinity.git'
developerConnection = 'scm:git:https://github.com/epam/ThreadAffinity.git'
url = 'https://github.com/epam/ThreadAffinity.git'
}
licenses {
license {
name = 'The Apache License, Version 2.0'
url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id = 'artsiomkorzun'
name = 'Artsiom Korzun'
email = 'humanfault101@gmail.com'
url = 'https://github.com/artsiomkorzun'
organization = 'EPAM Systems'
organizationUrl = 'https://www.epam.com/'
}
}
}
}
}
}
signing {
def signingKey = findProperty('SIGNING_PRIVATE_KEY') ?: System.getenv('SIGNING_PRIVATE_KEY') ?: "FakeUser"
def signingPassword = findProperty('SIGNING_PASSWORD') ?: System.getenv('SIGNING_PASSWORD') ?: "FakePass"
useInMemoryPgpKeys(signingKey, signingPassword)
sign publishing.publications.mavenJava
required { isReleaseVersion }
}
wrapper {
gradleVersion = '6.8'
distributionType = Wrapper.DistributionType.BIN
}