Skip to content
Amos Chua edited this page Oct 18, 2021 · 2 revisions

Tools Needed

Here is a list of tools required for the Azure v316 project.
You may need to download them if you don't already have them installed

Supported versions:

Target Tested
Java SDK Version Java 8 Update 231 Java 8 Update 261
IDE IntelliJ IntelliJ
DB Management System MariaDB MySQL 5.7.28
DB Administration Tool HeidiSQL MySQL Workbench 8.0 CE with WAMP 3.2

*If a tool is not listed in the table, its version doesn't matter.


Setup Guide

1. Clone or Fork this repository

Here are 3 ways you can do this:

Option 1: GitHub Desktop Route (GUI)

  • Make sure you have GitHub Desktop installed
  • In the toolbar, click File -> Clone repository...
    • Alternatively use the keyboard shortcut Ctrl+Shift+O
  • Click on the URL tab, and paste in https://github.com/Bratah123/ElectronMS
  • Set the Local path as the folder where you want the source code to be stored
  • Click Clone

Option 2: Sourcetree Route (GUI)

  • Make sure you have Sourcetree installed
  • In the toolbar, click File -> Clone/New...
    • Alternatively use the keyboard shortcut Ctrl+N
  • In the Source Path/URL field, paste in https://github.com/Bratah123/ElectronMS
  • In the Destination Path field, select the folder where you want the source code to be stored
  • Click Clone

Option 3: Command Line Route

  • Make sure you have Git installed
    • You can use the following command: choco install git if you are using Chocolatey to manage your software
    • Otherwise, install using the instructions from the Git Website
  • Navigate to the folder you want to use
    • E.g. cd server_tools/electron
  • Clone the repository
    • HTTPS: git clone https://github.com/Bratah123/ElectronMS.git
    • SSH: git clone git@github.com:Bratah123/ElectronMS.git
    • GitHub CLI: gh repo clone Bratah123/ElectronMS

2. Setup the DB management system

Either HeidiSQL or MySQL Workbench

  • Add a new connection (see last point for example)
  • By default the username may be set to root and the password left empty, with SSL disabled. Port should be set to 3306.
  • Note: Encoding is eucKR (not UTF-8), if you need to know
  • For MySQL Workbench (with WAMP/XAMP), see Steps 1-4 in here for more details

3. Setup the DB administration tool

Either HeidiSQL or MySQL Workbench

  • Run one of the SQL script files; see FAQ
  • It should create a new schema named kms_316.
  • Note: this will cause errors if MySQL Workbench is running in safe mode. Follow the error message instructions to disable safe mode.
  • For MySQL Workbench, see Steps 5-6 in here for more details

4. Turn off innodb strict mode - MariaDB only

  • This can be achieved by editing the .ini file in the install path of the DB management system, and requires a restart

5. Open the project in IntelliJ

  • When the project is first opened, the IDE will automatically start indexing all the files
  • Remember to allow the IDE to finish indexing
  • See here if you have difficulty doing so

6. Configure project settings

  • Import Maven build script, if the option is available: import maven build script

  • Else, go to File -> Settings..., search for runner, and select Delegate IDE build/run actions to Maven delegate actions to Maven

    • Note: You may try turning this off later if it doesn't build. This is just to make sure Maven grabs all dependencies.
  • Now double check that the project structure is configured properly.

7. Ensure that the details in Step 2 are reflected in the source code

  1. Hit Shift twice to bring up the search menu, and search for mysql.
  2. Select the first option.
  3. Check the username and password strings in MYSQL.java are correct.
    • Have it match your DB settings from earlier!
    • This reference screenshot uses defaults

8. Compile and Run

  • IMPORTANT: HeidiSQL or WAMP needs to be running in background
    • If you're using WAMP, the tray icon should be green:

Navigate to src\launcher to reach Start.java

  • Try Build and Run this file.
  • Note that the first build/run may take quite a while!
  • For subsequent runs, you may use the top right corner to run