forked from oracle/graalvm-reachability-metadata
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
47 lines (41 loc) · 1.3 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
/*
* Copyright and related rights waived via CC0
*
* You should have received a copy of the CC0 legalcode along with this
* work. If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
*/
plugins {
id 'base'
id "com.diffplug.spotless" version "6.3.0"
id "org.graalvm.internal.tck-harness"
}
allprojects {
repositories {
mavenCentral()
mavenLocal()
}
}
import static org.graalvm.internal.tck.TestUtils.metadataRoot
import static org.graalvm.internal.tck.TestUtils.repoRoot
import static org.graalvm.internal.tck.TestUtils.testRoot
project.version("0.2.4-SNAPSHOT")
// gradle check
spotless {
json {
target(metadataRoot + '/**/*.json', testRoot + '/**/*.json')
targetExclude(testRoot + '/**/build/**/*.json', repoRoot + '/.github/**/*.json')
gson()
.indentWithSpaces(2)
.sortByKeys()
.version("2.9.0")
}
}
// gradle package
tasks.register('package', Zip) { task ->
String outputFileName = "graalvm-reachability-metadata-${project.version}.zip"
task.setDescription("Packages current repository to 'build/${outputFileName}'")
task.setGroup(PublishingPlugin.PUBLISH_TASK_GROUP)
task.archiveFileName = outputFileName
task.destinationDirectory = layout.buildDirectory
from(metadataRoot)
}