-
Notifications
You must be signed in to change notification settings - Fork 1
Project Setup
Step 1: Download & Set-up Gradle
Follow the instructions from the Gradle site here.
Ensure that the gradle executable has been set-up in your path correctly by running the following in a command prompt or terminal:
gradle -vPlease restart any open IDEs so that they pick up the changes to the PATH variable.
Step 2: Clone Repository
Clone the repository by running the following command:
git clone https://github.com/NMAI-lab/SAVI.git
Step 3a: Command Line Project (No IDE)
This project can be run from the command line using Gradle. Please skip to step 4.
Step 3b: Import Gradle Project (IntelliJ Users Only)
Open IntelliJ IDEA
If you get the Welcome to IntelliJ IDEA dialog, continue to Step 3. Otherwise, skip to Step 4.
Import Project -> Skip to Step 5.
File -> New -> Project From Existing Sources
Navigate the dialog box to where the repository was cloned, select the build.gradle file, and click Ok.
Ensure that "Use auto-import" is checked. Select the "Use local Gradle distribution" radio button, and ensure that Gradle home points to the directory where Gradle was installed. Leave all other options as-is and select Ok.
Allow IntelliJ some time to index the files, download the Gradle dependencies, and set-up the project. Once this is complete, your development environment has been set up.
Step 3c: Import Gradle Project (Eclipse Users Only)
Open Eclipse
File -> Import... -> Gradle -> Existing Gradle Project -> Click Next.
Click Next if you get the Welcome Screen
Under Project root directory, enter the path for the cloned repository. Click Finish.
The project has been imported successfully.
Step 4: Running the Simulation
There are two ways of running the simulation:
Using an IDE (Eclipse / IntelliJ / etc.): You can start the simulation by running the SAVI_Controller class, located in savi/simulation.
Using a command prompt or terminal:
gradle run
Optional: Creating a Runnable Jar File
Creating a cross-platform JAR for the simulation can be done in one simple command:
gradle buildJar.The JAR file will be located under build/libs.
Additional Gradle Resources for Getting Started
Gradle utilizes the same project structure as Maven, so you can use this resource to understand how the project is laid out: Directory Structure
An additional resource for understanding Gradle directories and files can be found here.
The SAVI project - Carleton University, 2019.