forked from blair-robot-project/ballbasaur-rewrite
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
115 lines (98 loc) · 3.08 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
109
110
111
112
113
114
115
plugins {
id 'org.hidetake.ssh' version "2.9.0"
id 'java'
id 'eclipse'
id 'idea'
id 'jaci.openrio.gradle.GradleRIO' version "2017.1.5"
}
group 'org.usfirst.frc.team449.ballbasaur-rewrite'
version '1.0'
repositories {
mavenCentral()
maven {
name = "GradleRio"
url = "http://dev.imjac.in/maven"
}
maven { url "https://plugins.gradle.org/m2/" }
maven {
url 'https://jitpack.io'
}
}
wpi {
wpilibVersion = "2017.3.1" // The WPILib version to use. For this version of GradleRIO, must be a 2017 version.
ntcoreVersion = "3.1.7" // The NetworkTables Core version to use.
opencvVersion = "3.1.0" // The OpenCV version to use.
cscoreVersion = "1.0.2" // The CSCore version to use.
talonSrxVersion = "4.4.1.14" // The CTRE Toolsuite (Talon SRX) version to use.
navxVersion = "3.0.331" // The NavX-MXP library version to use.
}
dependencies {
compile 'com.github.blair-robot-project:449-central-repo:v6.1.0'
// https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind
compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.9.0.pr3'
// https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core
compile group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: '2.9.0.pr3'
// https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-annotations
compile group: 'com.fasterxml.jackson.core', name: 'jackson-annotations', version: '2.9.0.pr3'
compile group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-yaml', version: '2.9.0.pr3'
//com.fasterxml.jackson.module:jackson-module-parameter-names:2.9.0.pr3
compile group: 'com.fasterxml.jackson.module', name: 'jackson-module-parameter-names', version: '2.9.0.pr3'
compile 'org.jetbrains:annotations:13.0'
compile wpilib()
compile talonSrx()
compile navx()
}
/* GradleRIO stuff */
remotes {
rio {
host = 'roboRIO-449-frc.local'
user = 'lvuser'
knownHosts = allowAnyHosts
}
}
frc {
team = '449'
robotClass = "org.usfirst.frc.team449.robot.Robot"
}
def robotManifest = {
attributes 'Main-Class': 'edu.wpi.first.wpilibj.RobotBase'
attributes 'Robot-Class': frc.robotClass
}
task('copyResources') {
doLast {
ssh.run {
session(remotes.rio) {
execute 'mkdir ~/449_resources', ignoreError: true
execute 'mkdir ~/logs', ignoreError: true
put from: fileTree('src/main/resources'), into: './449_resources/'
execute ". /etc/profile.d/natinst-path.sh; /usr/local/frc/bin/frcKillRobot.sh -t -r", ignoreError: true
}
}
}
}
/* Generic artifact gen stuff */
jar {
from configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }
manifest robotManifest
}
task genJavadoc(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
task deleteDocs(type: Delete){
delete '../docs'
followSymlinks = false
}
task copyDocs(type: Copy, dependsOn: [genJavadoc, deleteDocs]){
from 'build/docs/javadoc'
into 'docs'
}
artifacts {
archives genJavadoc
}
compileJava {
options.compilerArgs << '-parameters'
}
task wrapper(type: Wrapper) {
gradleVersion = '4.2.1'
}