These instructions assume that you already have git and Eclipse configured.
-
Clone the repository with
git clone git@github.com:frc604/FRC-2016
-
The folder structure will now look something like this:
/path/to/repo/*FRC-2016*/(FRC-2016, README.md, etc)
In Eclipse, create a new workspace inside the first FRC-2016
folder (the folder surrounded by asterisks). Create a new "Robot Java Project" with the following settings:
Field|Value
-----|-----
Project Name|FRC-2016
Project Package|com.\_604robotics.robot2016
Project Type|Iterative Robot
- Delete the Robot.java file in the project directory.
-
When deploying code, Eclipse throws an error like "Unable to find Java compiler. Perhaps JAVA_HOME is not set to the JDK." This can happen for one of two reasons. If deploying works with one workspace but not another, skip to step 2.
JAVA_HOME
orPATH
does not contain the JDK path. On Windows, go toControl Panel > System and Security > System
and selectAdvanced System Settings
.
Select "Environmental Variables" and look for
JAVA_HOME
andPATH
variables. Make sure that a path likeC:\Program Files\Java\jdk1.8.0_65
is on eitherJAVA_HOME
orPATH
. If it is not, add the aforementioned path toPATH
.If this still doesn't work, move on to step 2.
- Eclipse is not configured to use the JDK.
In Eclipse, go to
Window > Preferences
and findJava > Installed JREs
and make sure thatjdk 1.8.0_65
or something similar is listed on the left. If onlyjre 1.8.0._65
is there, click "Add...".Select "Standard VM" and enter the path into "JRE home:". Click "Finish" and check for the
jdk 1.8.0_65
entry again. -
After cloning the code, the workspace path structure does not show existing paths as packages.
- This will happen if you attempt to add the project to an existing workspace. Make sure to add the project to a new workspace.
- If you are using Eclipse for C/C++ developers, packages may not show up either. This is simply cosmetic and should not affect development.
- This could also happen if you create the workspace in the wrong place. Please make sure to create a new workspace in the right place, as specified above. If you choose the wrong folder to create the workspace in, the resulting project will have the wrong layout.
-
Do not add any code that isn't already public! All code added before build season (January 9, 2016) must be available publicly. This is to comply with FRC rules.
- Continue to update troubleshooting instructions as necessary
- See if project can be added to existing workspace instead of new one: Project must be added to new workspace.
- Possibly add instructions as to cloning first and importing the code in another workspace?