Skip to content

Latest commit

 

History

History
127 lines (85 loc) · 3.32 KB

development_guide.md

File metadata and controls

127 lines (85 loc) · 3.32 KB

Development Guide

In a post-it

# Install NodeJS v16
nvm use 16
npm install -g yarn 

# Clone and compile from source
git clone [email protected]:clients/cesium-grp/cesium.git
cd cesium
yarn

# Run the App !
yarn run start

Step by step

Prerequisite

To build Cesium, you will have to:

  1. Installing build tools:

       sudo apt-get install git wget curl unzip build-essential software-properties-common ruby ruby-dev ruby-ffi gcc make
  2. Installing node.js v16 :

  • First, install nvm (Node Version Manager) :

       wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.1/install.sh | bash

    Alternatively, if you are using fish shell, there is a dedicated plugin.

  • Then, reload your terminal (for instance by executing the command bash);

  • Configure nvm to use the expected version: (WARNING: upper version will NOT work !)

       nvm install 16
  1. Installing node build tools, as global dependencies:
       npm install -g yarn gulp cordova @ionic/[email protected] web-ext

Get the source code and dependencies

  1. Getting the source code:
   git clone [email protected]:clients/cesium-grp/cesium.git
  1. Install project dependencies:

       cd cesium
       yarn
  2. Installing Cordova plugins (required to build Android and iOS artifacts):

       export JAVA_HOME=/path/to/jdk-11
       export PATH=$JAVA_HOME/bin:$PATH
       ionic cordova prepare

    This should create new directories platforms/android and platforms/ios.

    As a reminder: check that your command line is well configured:

    • You must place yourself in the directory of the application: cd cesium
    • and working with NodeJs v16: nvm use 16 (please check using the command node --version)

Prepare configuration file

Configure Cesium default settings :

  1. Add your environment config into app/config.json

  2. Update default configuration, using the command:

       gulp config --env <your_env_name> 

This will update a configuration file www/js/config.json.

Compile and launch

To compile and launch Cesium, run:

  yarn run start

or alternative: npm start or ionic serve

The application should be running at localhost:8100!

Build artifacts

Cesium can be build:

You may also use Docker image to simplify this task;

Time to code !

Pull request

For each pull request, please create an issue first.

Best practices for development

Cesium could be run on phone devices. Please read performance tips on AgularJS + Ionic before starting to contribute.

Read also Angular performance for large applicatoins.