File tree 1 file changed +9
-7
lines changed
1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,15 @@ plugins {
12
12
id " biz.aQute.bnd.builder" version " 6.4.0"
13
13
}
14
14
15
+ if (JavaVersion . current() != JavaVersion . VERSION_1_8 ) {
16
+ def msg = String . format(" This build must be run with java 1.8 - you are running %s - gradle finds the JDK via JAVA_HOME=%s" ,
17
+ JavaVersion . current(), System . getenv(" JAVA_HOME" ))
18
+ throw new GradleException (msg)
19
+ }
20
+
21
+ sourceCompatibility = 1.8
22
+ targetCompatibility = 1.8
23
+
15
24
def getDevelopmentVersion () {
16
25
def output = new StringBuilder ()
17
26
def error = new StringBuilder ()
@@ -25,18 +34,11 @@ def getDevelopmentVersion() {
25
34
" 0.0.0-" + new SimpleDateFormat (' yyyy-MM-dd\' T\' HH-mm-ss' ). format(new Date ()) + " -" + gitHash
26
35
}
27
36
28
-
29
37
def releaseVersion = System . env. RELEASE_VERSION
30
38
version = releaseVersion ? releaseVersion : getDevelopmentVersion()
31
39
println " Building version = " + version
32
40
group = ' com.graphql-java'
33
41
34
- java {
35
- toolchain {
36
- languageVersion = JavaLanguageVersion . of(8 )
37
- }
38
- }
39
-
40
42
repositories {
41
43
mavenCentral()
42
44
mavenLocal()
You can’t perform that action at this time.
0 commit comments