Skip to content

Commit 5ae2016

Browse files
committed
moved test robot code 2019.4.1 version to repo
1 parent b47cc1b commit 5ae2016

File tree

17 files changed

+864
-0
lines changed

17 files changed

+864
-0
lines changed

.gitignore

Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,160 @@
11
.gradle
22
/build/
33

4+
/.idea/
5+
6+
# Ignore Gradle GUI config
7+
gradle-app.setting
8+
9+
# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored)
10+
!gradle-wrapper.jar
11+
12+
# Cache of project
13+
.gradletasknamecache
14+
15+
# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898
16+
# gradle/wrapper/gradle-wrapper.properties
17+
18+
# Created by https://www.gitignore.io/api/c++,java,linux,macos,gradle,windows,visualstudiocode
19+
20+
### C++ ###
21+
# Prerequisites
22+
*.d
23+
24+
# Compiled Object files
25+
*.slo
26+
*.lo
27+
*.o
28+
*.obj
29+
30+
# Precompiled Headers
31+
*.gch
32+
*.pch
33+
34+
# Compiled Dynamic libraries
35+
*.so
36+
*.dylib
37+
*.dll
38+
39+
# Fortran module files
40+
*.mod
41+
*.smod
42+
43+
# Compiled Static libraries
44+
*.lai
45+
*.la
46+
*.a
47+
*.lib
48+
49+
# Executables
50+
*.exe
51+
*.out
52+
*.app
53+
54+
### Java ###
55+
# Compiled class file
56+
*.class
57+
58+
# Log file
59+
*.log
60+
61+
# BlueJ files
62+
*.ctxt
63+
64+
# Mobile Tools for Java (J2ME)
65+
.mtj.tmp/
66+
67+
# Package Files #
68+
*.jar
69+
*.war
70+
*.nar
71+
*.ear
72+
*.zip
73+
*.tar.gz
74+
*.rar
75+
76+
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
77+
hs_err_pid*
78+
79+
### Linux ###
80+
*~
81+
82+
# temporary files which can be created if a process still has a handle open of a deleted file
83+
.fuse_hidden*
84+
85+
# KDE directory preferences
86+
.directory
87+
88+
# Linux trash folder which might appear on any partition or disk
89+
.Trash-*
90+
91+
# .nfs files are created when an open file is removed but is still being accessed
92+
.nfs*
93+
94+
### macOS ###
95+
# General
96+
.DS_Store
97+
.AppleDouble
98+
.LSOverride
99+
100+
# Icon must end with two \r
101+
Icon
102+
103+
# Thumbnails
104+
._*
105+
106+
# Files that might appear in the root of a volume
107+
.DocumentRevisions-V100
108+
.fseventsd
109+
.Spotlight-V100
110+
.TemporaryItems
111+
.Trashes
112+
.VolumeIcon.icns
113+
.com.apple.timemachine.donotpresent
114+
115+
# Directories potentially created on remote AFP share
116+
.AppleDB
117+
.AppleDesktop
118+
Network Trash Folder
119+
Temporary Items
120+
.apdisk
121+
122+
### VisualStudioCode ###
123+
.vscode/*
124+
!.vscode/settings.json
125+
!.vscode/tasks.json
126+
!.vscode/launch.json
127+
!.vscode/extensions.json
128+
129+
### Windows ###
130+
# Windows thumbnail cache files
131+
Thumbs.db
132+
ehthumbs.db
133+
ehthumbs_vista.db
134+
135+
# Dump file
136+
*.stackdump
137+
138+
# Folder config file
139+
[Dd]esktop.ini
140+
141+
# Recycle Bin used on file shares
142+
$RECYCLE.BIN/
143+
144+
# Windows Installer files
145+
*.cab
146+
*.msi
147+
*.msix
148+
*.msm
149+
*.msp
150+
151+
# Windows shortcuts
152+
*.lnk
153+
154+
### Gradle ###
155+
.gradle
156+
/build/
157+
4158
# Ignore Gradle GUI config
5159
gradle-app.setting
6160

@@ -12,3 +166,12 @@ gradle-app.setting
12166

13167
# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898
14168
# gradle/wrapper/gradle-wrapper.properties
169+
170+
# # VS Code Specific Java Settings
171+
.classpath
172+
.project
173+
.settings/
174+
bin/
175+
176+
177+
# End of https://www.gitignore.io/api/c++,java,linux,macos,gradle,windows,visualstudiocode

.vscode/launch.json

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
// Use IntelliSense to learn about possible attributes.
3+
// Hover to view descriptions of existing attributes.
4+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5+
"version": "0.2.0",
6+
"configurations": [
7+
8+
{
9+
"type": "wpilib",
10+
"name": "WPILib Desktop Debug",
11+
"request": "launch",
12+
"desktop": true,
13+
},
14+
{
15+
"type": "wpilib",
16+
"name": "WPILib roboRIO Debug",
17+
"request": "launch",
18+
"desktop": false,
19+
}
20+
]
21+
}

.vscode/settings.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"java.configuration.updateBuildConfiguration": "automatic",
3+
"files.exclude": {
4+
"**/.git": true,
5+
"**/.svn": true,
6+
"**/.hg": true,
7+
"**/CVS": true,
8+
"**/.DS_Store": true,
9+
"bin/": true,
10+
".classpath": true,
11+
".project": true
12+
}
13+
}

.wpilib/wpilib_preferences.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"enableCppIntellisense": false,
3+
"currentLanguage": "java",
4+
"projectYear": "2019",
5+
"teamNumber": 3158
6+
}

build.gradle

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
plugins {
2+
id "java"
3+
id "edu.wpi.first.GradleRIO" version "2019.4.1"
4+
}
5+
6+
sourceCompatibility = JavaVersion.VERSION_1_8
7+
targetCompatibility = JavaVersion.VERSION_1_8
8+
9+
def ROBOT_MAIN_CLASS = "frc.robot.Main"
10+
11+
// Define my targets (RoboRIO) and artifacts (deployable files)
12+
// This is added by GradleRIO's backing project EmbeddedTools.
13+
deploy {
14+
targets {
15+
roboRIO("roborio") {
16+
// Team number is loaded either from the .wpilib/wpilib_preferences.json
17+
// or from command line. If not found an exception will be thrown.
18+
// You can use getTeamOrDefault(team) instead of getTeamNumber if you
19+
// want to store a team number in this file.
20+
team = frc.getTeamNumber()
21+
}
22+
}
23+
artifacts {
24+
frcJavaArtifact('frcJava') {
25+
targets << "roborio"
26+
// Debug can be overridden by command line, for use with VSCode
27+
debug = frc.getDebugOrDefault(false)
28+
}
29+
// Built in artifact to deploy arbitrary files to the roboRIO.
30+
fileTreeArtifact('frcStaticFileDeploy') {
31+
// The directory below is the local directory to deploy
32+
files = fileTree(dir: 'src/main/deploy')
33+
// Deploy to RoboRIO target, into /home/lvuser/deploy
34+
targets << "roborio"
35+
directory = '/home/lvuser/deploy'
36+
}
37+
}
38+
}
39+
40+
// Set this to true to enable desktop support.
41+
def includeDesktopSupport = false
42+
43+
// Maven central needed for JUnit
44+
repositories {
45+
mavenCentral()
46+
}
47+
48+
// Defining my dependencies. In this case, WPILib (+ friends), and vendor libraries.
49+
// Also defines JUnit 4.
50+
dependencies {
51+
compile wpi.deps.wpilib()
52+
compile wpi.deps.vendor.java()
53+
nativeZip wpi.deps.vendor.jni(wpi.platforms.roborio)
54+
nativeDesktopZip wpi.deps.vendor.jni(wpi.platforms.desktop)
55+
testCompile 'junit:junit:4.12'
56+
}
57+
58+
// Setting up my Jar File. In this case, adding all libraries into the main jar ('fat jar')
59+
// in order to make them all available at runtime. Also adding the manifest so WPILib
60+
// knows where to look for our Robot Class.
61+
jar {
62+
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
63+
manifest edu.wpi.first.gradlerio.GradleRIOPlugin.javaManifest(ROBOT_MAIN_CLASS)
64+
}

gradle/wrapper/gradle-wrapper.jar

54.4 KB
Binary file not shown.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
distributionBase=GRADLE_USER_HOME
2+
distributionPath=permwrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.0-bin.zip
4+
zipStoreBase=GRADLE_USER_HOME
5+
zipStorePath=permwrapper/dists

0 commit comments

Comments
 (0)