-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.gradle
More file actions
126 lines (98 loc) · 3.71 KB
/
build.gradle
File metadata and controls
126 lines (98 loc) · 3.71 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
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
122
123
124
125
126
import org.apache.maven.shared.model.fileset.FileSet
import org.web3j.mavenplugin.JavaClassGeneratorMojo
buildscript {
ext {
kotlinVersion = '1.3.21'
springBootVersion = '2.1.6.RELEASE'
}
repositories {
mavenCentral()
maven { url 'https://dl.bintray.com/ethereum/maven/' }
maven { url 'https://plugins.gradle.org/m2/' }
}
dependencies {
classpath("org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.8.2")
classpath("org.web3j:web3j-maven-plugin:0.3.0")
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${kotlinVersion}")
classpath("org.jetbrains.kotlin:kotlin-allopen:${kotlinVersion}")
}
}
apply plugin: 'kotlin'
apply plugin: 'kotlin-spring'
apply plugin: 'eclipse'
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
apply plugin: 'jacoco'
apply plugin: 'com.github.kt3k.coveralls'
apply from: "$rootDir/ktlint.gradle"
apply from: "$rootDir/bumpVersion.gradle"
group = 'com.bitclave.node'
version = '0.0.1'
sourceCompatibility = 1.8
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
bootJar {
archiveFileName = "base-node.jar"
}
jacocoTestReport {
reports {
xml.enabled = true
html.enabled = true
}
afterEvaluate {
//noinspection GroovyAssignabilityCheck
classDirectories = files(classDirectories.files.collect {
fileTree(dir: it, exclude: ['com/bitclave/node/services/errors/**', '**/generated/**'])
})
}
}
coveralls {
sourceDirs += ['src/main/kotlin']
}
compileKotlin.dependsOn ktlint
task compileSolidity(type: JavaExec) {
def solidityGenerator = new JavaClassGeneratorMojo()
def fields = solidityGenerator.class.declaredFields
def path = new FileSet()
def pathMain = projectDir.toString().replaceAll("\\\\", "/") + "/src/main"
fields.each { it.setAccessible(true) }
path.setDirectory(pathMain + "/resources/")
solidityGenerator.packageName = "com.bitclave.node.solidity.generated"
solidityGenerator.sourceDestination = pathMain + "/java/"
solidityGenerator.soliditySourceFiles = path
solidityGenerator.nativeJavaType = true
solidityGenerator.execute()
}
repositories {
mavenCentral()
maven { url 'https://dl.bintray.com/ethereum/maven/' }
maven { url 'https://plugins.gradle.org/m2/' }
}
dependencies {
compile 'org.web3j:core:3.3.1'
compile 'org.springframework.boot:spring-boot-configuration-processor'
compile("org.springframework.boot:spring-boot-starter-web")
compile("org.springframework.boot:spring-boot-starter-actuator")
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8:${kotlinVersion}"
compile "org.jetbrains.kotlin:kotlin-reflect:${kotlinVersion}"
compile 'io.springfox:springfox-swagger2:2.8.0'
compile 'io.springfox:springfox-swagger-ui:2.8.0'
compile 'com.google.code.gson:gson:2.8.5'
compile 'org.bouncycastle:bcprov-jdk15on:1.59'
compile 'org.bitcoinj:bitcoinj-core:0.14.5'
compile 'org.springframework.boot:spring-boot-starter-data-jpa'
compile 'org.postgresql:postgresql:42.2.5'
compile 'javax.xml.bind:jaxb-api:2.3.0'
compile 'net.logstash.logback:logstash-logback-encoder:6.1'
compile("org.springframework.boot:spring-boot-starter-websocket")
// https://mvnrepository.com/artifact/com.appoptics.metrics/appoptics-api-java
compile group: 'com.appoptics.metrics', name: 'appoptics-api-java', version: '1.0.5'
testCompile 'org.springframework.boot:spring-boot-starter-test'
testCompile 'com.h2database:h2'
}
compileJava.dependsOn(processResources)