fieldviewloader

1.3.2 • Public • Published

fieldviewloader

CLI tool for loading data to Mapbox and the fieldviewapi.

Assumes Node and NPM are installed on your system. To install the project's dependencies and development dependencies change to the project's root directory and run

$ npm install

Internally this application uses GDAL and several GDAL utilities. Please ensure that the GDAL_DATA variable is set for your system and that the directory containing your GDAL executables is in the PATH variable.

To run tests

$ npm test

Before running locally the application requires several environment variables to be set for API authentication. These can be set using

$ export MAPBOX_TOKEN=yourMapboxToken
$ export ADMIN_EMAIL=yourFieldViewAPIAdminEmail
$ export ADMIN_PASSWORD=yourFieldViewAPIAdminPassword

The Mapbox token should have write and read scopes as described here

The application requires an instance of the fieldviewapi running in the background for local testing.

To create shapefiles for uploading to Mapbox for Fields and Labels run

$ createMapboxShapes pathToYourMasterShapefile

The resulting shapefiles can be zipped and used to replace the Fields and Labels data sources in Mapbox.

To add new fields to the FieldView API run

$ fieldloader pathToYourNewFieldsShapefile

To upload new images to the FieldView API and Mapbox, navigate to the images directory and run

$ fieldviewloader

Readme

Keywords

none

Package Sidebar

Install

npm i fieldviewloader

Weekly Downloads

1

Version

1.3.2

License

ISC

Last publish

Collaborators

  • sharkinsgis