Build

Main tech stack

  • Spring Boot 2
  • React 16
  • SQLite 3

Prerequisite

  • Node.js
  • Maven
  • SQLite 3 CLI
  • JDK 1.8+

Building

  • Clone or download the repository.
  • Install the npm packages only the first time.
  1. cd web-app
  2. npm install
  • Run the build script.
  1. # Windows
  2. build.bat
  3. # Linux
  4. ./build.sh
  • The java executable poli-x.y.z.jar is generated under the target folder. Run this to start the server.
  1. java -jar target\poli-x.y.z.jar

Source code structure

  1. |-- Repository
  2. |-- config
  3. |-- poli.properties
  4. |-- db
  5. |-- schema-sqlite.sql
  6. |-- src
  7. |-- web-app
  8. |-- pom.xml
  9. |-- build.sh
  10. |-- build.bat
  11. |...
  • Src folder contains the java source code.
  • Web-app folder contains the react code.
  • Schema-sqlite.sql contains the database schema for SQLite 3. The poli.db file in the release is loaded from this schema.
  • The build scripts build the code in web-app first, copy the generated files to src ~/static folder and finally run maven to build the java project.