forked from MicroShed/lsp4ij
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
108 lines (96 loc) · 2.96 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
plugins {
id 'org.jetbrains.intellij' version '1.13.3'
id 'java'
id 'java-library'
id 'maven-publish'
}
group 'org.microshed'
version '0.0.1'
sourceCompatibility = 11
targetCompatibility = 11
compileJava.options.debugOptions.debugLevel = "source,lines,vars"
compileTestJava.options.debugOptions.debugLevel = "source,lines,vars"
repositories {
mavenCentral()
maven {
url 'https://repo.eclipse.org/content/repositories/snapshots'
}
maven {
url 'https://repo.eclipse.org/content/repositories/releases'
}
maven {
url "https://oss.sonatype.org/content/repositories/snapshots"
}
maven {
url = "https://packages.jetbrains.team/maven/p/ij/intellij-dependencies"
}
maven {
url = "https://www.jetbrains.com/intellij-repository/releases"
}
maven {
url = "https://packages.jetbrains.team/maven/p/kpm/public"
}
maven {
url = "https://cache-redirector.jetbrains.com/packages.jetbrains.team/maven/p/grazi/grazie-platform-public"
}
maven {
url = "https://download.jetbrains.com/teamcity-repository"
}
maven {
url = "https://cache-redirector.jetbrains.com/download-pgp-verifier"
}
mavenLocal() // TODO remove once Liberty LS is publicly available
}
publishing {
publications {
library(MavenPublication) {
from components.java
}
}
}
configurations {
// needed to avoid ClassCastException org.apache.xerces.jaxp.DocumentBuilderFactoryImpl cannot be cast to class javax.xml.parsers.DocumentBuilderFactory
// xml-apis interfering with xercs
all*.exclude group: 'xml-apis'
runtimeClasspath {
exclude group: 'org.slf4j', module: 'slf4j-api'
}
}
dependencies {
implementation 'org.eclipse.lsp4j:org.eclipse.lsp4j:0.21.0'
implementation 'org.eclipse.lsp4j:org.eclipse.lsp4j.jsonrpc:0.21.0'
//required by lsp4j as the version from IJ is incompatible
implementation 'com.google.code.gson:gson:2.8.9'
//Add junit dependency back when tests are added
}
configurations.implementation.setCanBeResolved(true)
jar {
manifest {
attributes "Main-Class": "MainClass"
}
from {
configurations.implementation.collect { it.isDirectory() ? it : zipTree(it) }
} {
exclude "META-INF/*.SF"
exclude "META-INF/*.DSA"
exclude "META-INF/*.RSA"
duplicatesStrategy 'include' // error copying duplicate about.html
}
from { sourceSets.main.allSource } {
duplicatesStrategy 'exclude' // error copying .properties when adding source to jar
}
extension 'jar'
}
intellij {
// For a full list of IntelliJ IDEA releases please see https://www.jetbrains.com/intellij-repository/releases
version = '2022.2'
updateSinceUntilBuild = false
plugins = ['java', 'gradle-java', 'com.intellij.gradle']
}
test {
useJUnitPlatform()
testLogging {
showStandardStreams = true
exceptionFormat = 'full'
}
}