Build Instructions

This section contains the build instructions from the source code available at our GitHub page.

Development Setup

Prerequisites

Java Development Kit: This project requires Java Development Kit (JDK) 11 to be compiled. This is the same Java version that comes with WPILib. If you don’t have this JDK with WPILib, you can follow the instructions to install JDK 11 for your platform here.
Node JS: The UI is written in Node JS. To compile the UI, Node 10 or newer is required. To install Node JS follow the instructions for your platform on the official Node JS website.

Compiling Instructions

Getting the Source Code

Get the source code from git:

git clone https://github.com/PhotonVision/photonvision

or alternatively download to source code from github and extract the zip:

Download source code from git

Install Necessary Node JS Dependencies

In the photon-client directory:

npm install

Build and Copy UI to Java Source

In the photon-server directory:

./gradlew buildAndCopyUI

./gradlew buildAndCopyUI

gradlew buildAndCopyUI

Build and Run the Source

To compile and run the project, issue the following command in the photon-server directory:

./gradlew run

./gradlew run

gradlew run

Running the following command under the photon-server directory will build the jar under photon-server/build/libs:

./gradlew shadowJar

./gradlew shadowJar

gradlew shadowJar