Skip to content

Latest commit

 

History

History
129 lines (83 loc) · 2.76 KB

developer-guide.md

File metadata and controls

129 lines (83 loc) · 2.76 KB

Developer Guide

This guide helps you get started developing APITable.

Dependencies

Make sure you have the following dependencies and programming languages installed before setting up your developer environment:

Programming Language

If you are using macOS or Linux. We recommend install programming language with SDK manager sdkman and nvm.

# quick install nvm
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.2/install.sh | bash
# quick install sdkman
curl -s "https://get.sdkman.io" | bash
# install nodejs 
nvm install 16.15.0 && nvm use 16.15.0 && corepack enable
# install java development kit
sdk env install
# install rust toolchain
curl -sSf https://sh.rustup.rs | sh -s -- --default-toolchain nightly --profile minimal -y && source "$HOME/.cargo/env"

macOS

We recommend using Homebrew for installing any missing dependencies:

## necessary required
brew install git
brew install --cask docker
brew install make

Linux

On CentOS / RHEL or other Linux distribution with yum

sudo yum install git
sudo yum install make

On Ubuntu / Debian or other Linux distribution with apt

sudo apt update
sudo apt install git
sudo apt install make

Windows

If you are running APITable on Windows 10/11, we recommend installing Docker Desktop on Windows, Ubuntu on WSL and Windows Terminal, You can learn more about Windows Subsystem for Linux (WSL) in the official site.

Install missing dependencies on Ubuntu using apt:

sudo apt update
sudo apt install git
sudo apt install make

Build Tool

We use make as our centric build tool entry that drives other build tool like gradle / npm / yarn.

So you can just input make command and see all build commands:

make

make command screenshot

Start Development Environment

APITable consists of 3 processes:

  1. backend-server
  2. room-server
  3. web-server

To start the development environment locally, run these commands:

# start databases in dockers
make dataenv 

# install dependencies
make install 

#start backend-server
make run # enter 1  

# and then switch to a new terminal
# start room-server
make run # enter 2

# and then switch to a new terminal
# start web-server
make run # enter 3

IDE

We recommend you use Visual Studio Code or Intellij IDEA for your IDE.

APITable have prepared these two IDE's debug configs.

Just open APITable's root directory with IDE.