unicef/majicbox

Name: majicbox

Owner: unicef

Description: null

Created: 2016-02-25 23:39:59.0

Updated: 2017-05-26 23:10:39.0

Pushed: 2017-02-18 02:57:13.0

Homepage: null

Size: 19718

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

![image](https://travis-ci.org/unicef/majicbox.svg?branch=master Travis CI build status)

Setup for developers

The Database

This application uses Mongodb for its database. You will need to have it installed to use it. Check out the Mongodb installation information at:

http://docs.mongodb.org/manual/tutorial/install-mongodb-on-os-x/
https://www.digitalocean.com/community/tutorials/how-to-install-mongodb-on-ubuntu-16-04
Installation

Deprecated:

Workflow and guidelines

Before submitting any code, one should run:

It's a little slower (container overhead) but you can run make lint utest-in-docker to run the same commands as Travis CI. This should eliminate any local state you may have hanging around. We now have checks on every pull request, which is great because we should never have our master branch breaking tests.

Linting

Code should ideally pass eslint. We use the Google style guide as a base configuration with some slight modifications. The .eslintrc is committed to the repo, so whenever you run make lint, the config should take effect.

nodemon

nodemon is like node, but automatically reloads code when the code is updated.

install -g nodemon
_ENV=development nodemon server.js 8002
Importing a new country
Get shapefile
Convert shapefile to geojson

This process requires the GDAL - Geospatial Data Abstraction Library

(On Mac OSX: brew install gdal)

node lib/import/admin.js -f './data/geojson/br/admin2.json' -c 'co' --verbose true node lib/import/admin.js -s 'gadm2-8' -c 'arg' -a 2 --verbose true


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.