This is a step-by-step guide to setting up a development environment in your local machine. You will use that environment to work on features, enhancements, bug fixes, etc. which ultimately allows you to contribute to the project.
The instructions in all parts of this document work for Linux, OS X, and Windows, with the following pointers:
- Replace
./gradlew
togradlew.bat
if you are using Windows. - All the commands are assumed to be run from the root project folder, unless otherwise specified.
- When a version is specified for any tool, install that version instead of the latest version available.
If you encounter any problems during the setting up process, please refer to our troubleshooting guide before posting a help request in our issue tracker.
- Install Source Tree or other similar Git Client, or at least Git.
- Install JDK 1.8.
- Install Python 2.7.
- Install Node.js (minimum version 4.x).
-
Fork our repo at https://github.com/TEAMMATES/teammates. Clone that fork to your hard disk.
-
Add a remote name (e.g
upstream
) for the main repo for your repo to keep in sync with.git remote add upstream https://github.com/TEAMMATES/teammates.git
Verification: Use the command
git remote -v
and the following lines should be part of the output:upstream https://github.com/TEAMMATES/teammates.git (fetch) upstream https://github.com/TEAMMATES/teammates.git (push)
-
Set your
master
branch to track the main repo'smaster
branch.git checkout master git branch -u upstream/master
More information can be found at this documentation.
-
Install Google Cloud SDK version 179.0.0. Follow the directions given here. Note that you do not need to initialize the SDK.
# This command is to be run at the Google Cloud SDK directory # Linux/OS X ./install.sh --path-update true # Windows install.bat --path-update true
Verification: Run a
gcloud
command (e.g.gcloud version
) in order to verify that you can access the SDK from the command line. -
Run this command to install App Engine Java SDK bundled with the Cloud SDK:
gcloud -q components install app-engine-java
Verification: Run
gcloud version
and there should be an entry onapp-engine-java
. -
Run this command to download the necessary tools for JavaScript development:
npm install
Verification: A folder named
node_modules
should be added to the project root directory. -
Run this command to create the main config files (these are not under revision control because their contents vary from developer to developer):
./gradlew createConfigs
Verification: The file named
gradle.properties
should be added to the project root directory. -
Modify the following config file:
gradle.properties
If you want to use a JDK other than the one specified in your PATH variable, add the value to the variableorg.gradle.java.home
. This value must be a valid JDK 1.8 directory. Windows users should use a forward slash (/
) instead of the Windows default backward slash (\
) while specifying the path.
You are encouraged, but not required, to use an IDE to assist many development tasks.
We currently support two IDEs: Eclipse IDE and IntelliJ IDEA. Support requests related to other IDEs will not be entertained.
Refer to this document if you wish to set up an IDE for developing TEAMMATES.
If you followed every step correctly, you should have successfully set up the development environment.
Proceed to the development routine as outlined in this document.