-
Notifications
You must be signed in to change notification settings - Fork 41
/
build.gradle
121 lines (108 loc) · 3.71 KB
/
build.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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
plugins {
id 'idea'
id 'java-library'
id 'maven'
id 'signing'
id 'maven-publish'
id 'com.google.protobuf' version '0.8.15'
id 'io.freefair.lombok' version '5.3.3.3'
id "io.github.gradle-nexus.publish-plugin" version "1.1.0"
}
group 'org.raystack'
version '0.5.1'
repositories {
mavenLocal()
mavenCentral()
}
dependencies {
implementation group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.25'
api group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.6'
api group: 'com.google.protobuf', name: 'protobuf-java', version: '3.5.1'
implementation group: 'com.google.guava', name: 'guava', version: '27.0.1-jre'
api group: 'com.datadoghq', name: 'java-dogstatsd-client', version: '2.13.0'
implementation group: 'org.json', name: 'json', version:'20211205'
testImplementation group: 'junit', name: 'junit' , version: '4.12'
testImplementation group: 'com.github.tomakehurst', name: 'wiremock', version: '2.18.0'
testImplementation group: 'com.google.guava', name: 'guava-testlib', version: '12.0-rc2'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.1.0'
testImplementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.7'
}
protobuf {
generatedFilesBaseDir = "$projectDir/src/test/generated"
protoc {
artifact = "com.google.protobuf:protoc:3.5.1"
}
generateProtoTasks {
all().each { task ->
task.generateDescriptorSet = true
task.descriptorSetOptions.includeSourceInfo = false
task.descriptorSetOptions.includeImports = true
task.descriptorSetOptions.path = "$projectDir/src/test/resources/__files/descriptors.bin"
}
}
}
idea {
module {
testSourceDirs += file("$projectDir/src/generated/test/java")
}
}
java {
withJavadocJar()
withSourcesJar()
}
publishing {
repositories {
maven {
name = "OSSRH"
url = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
credentials {
username = System.getenv("MAVEN_USERNAME")
password = System.getenv("MAVEN_PASSWORD")
}
}
}
publications {
maven(MavenPublication) {
pom {
name = 'Stencil'
description = 'Library to pull latest proto descriptors from a remote server'
url = 'https://github.com/raystack/stencil'
scm {
url = 'https://github.com/raystack/stencil.git'
}
licenses {
license {
name = 'The Apache License, Version 2.0'
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id = 'harikrishnakanchi'
name = 'Hari Krishna'
email = '[email protected]'
}
developer {
id = 'ravisuhag'
name = 'Ravi Suhag'
email = '[email protected]'
}
}
from components.java
}
}
}
}
signing {
sign publishing.publications.maven
}
nexusPublishing {
repositories {
sonatype {
nexusUrl.set(uri("https://s01.oss.sonatype.org/service/local/"))
snapshotRepositoryUrl.set(uri("https://s01.oss.sonatype.org/content/repositories/snapshots/"))
username = System.getenv("MAVEN_USERNAME")
password = System.getenv("MAVEN_PASSWORD")
}
}
}