-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
87 lines (70 loc) · 2.79 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
//
// build.gradle in TeamCode
//
// Most of the definitions for building your module reside in a common, shared
// file 'build.common.gradle'. Being factored in this way makes it easier to
// integrate updates to the FTC into your code. If you really need to customize
// the build definitions, you can place those customizations in this file, but
// please think carefully as to whether such customizations are really necessary
// before doing so.
// Custom definitions may go here
plugins {
id "com.github.node-gradle.node" version "3.0.1"
}
// Include common definitions from above.
apply from: '../build.common.gradle'
apply from: '../build.dependencies.gradle'
android {
namespace = 'org.firstinspires.ftc.teamcode'
}
dependencies {
implementation project(':FtcRobotController')
annotationProcessor files('lib/OpModeAnnotationProcessor.jar')
implementation 'junit:junit:4.13.2'
testImplementation 'junit:junit:4.13.2'
//implementation 'org.jetbrains:annotations-java5:23.0.0'
implementation 'org.apache.commons:commons-math3:3.6.1'
implementation 'com.acmerobotics.roadrunner:core:0.5.5'
}
task autoautoCompiler(type: NodeTask) {
args = ["--build-history", "--agpbi", "--make-tests", "--run-cleanup",
//The `--in` and `--out` arguments use GStrings, a fancy way of putting strings together.
//See <http://docs.groovy-lang.org/latest/html/documentation/index.html#all-strings> for more info.
"--in=${file("src/main/java")}", "--in=${file("src/test/java")}", //Directories to take Autoauto files from
"--out=${file("gen")}", //directory to put generated opmodes into
"--test-dir=${file("src/test/java")}", //directory to toss tests into
"--assets-dir=${file("src/main/assets")}", //directory to put build-history into
"--java-class-suffix=Manager", //only look for methods in java classes that end with 'Manager'
"--java-functions-dir=${file("src/main/java/org/firstinspires/ftc/teamcode/managers")}", //directory to look for Java methods in
"--output-java-template=${file("src/main/java/org/firstinspires/ftc/teamcode/autoauto-template.notjava")}" //template for autoauto opmodes
]
script = file("src/main/scripts/autoauto-compiler/index.js")
}
android {
androidResources {
noCompress 'tflite'
}
gradle.projectsEvaluated {
preBuild.dependsOn(autoautoCompiler)
}
sourceSets {
test {
java.srcDir("gen/")
java.srcDir("src/test/java")
}
debug {
java.srcDir("gen/")
}
main {
java.srcDir("gen/")
}
}
defaultConfig {
minSdkVersion 23
}
}
node {
download = true
version = "12.18.3"
distBaseUrl = "https://nodejs.org/dist"
}