bodytrack-datastore
v4.3.7
Published
A Node.js interface for the BodyTrack Datastore.
Downloads
40
Readme
Bodytrack Datastore
A Node.js interface for the BodyTrack Datastore (https://github.com/BodyTrack/datastore).
Tested against Node.js v18.17.0. Previously tested against v14.15.0 and v16.14.2.
Installation
This module requires an installation of the BodyTrack Datastore somewhere on your system. If you don't have it already, do the following:
Fetch the BodyTrack Datastore:
git clone https://github.com/BodyTrack/datastore.git
Follow the build and install instructions for the BodyTrack Datastore.
Install this module in the usual way:
npm install bodytrack-datastore
Do the following if you want to run this module's tests:
Copy this project's
test/config.template.js
file totest/config.js
.Edit
config.js
as appropriate for your installation of the BodyTrack Datastore.Run the tests:
npm test
Usage
This module provides a class named BodyTrackDatastore
. Create a new instance like this:
var BodyTrackDatastore = require('bodytrack-datastore');
var datastore = new BodyTrackDatastore({
binDir: "/PATH/TO/DATASTORE/BIN/DIRECTORY",
dataDir: "/PATH/TO/DATASTORE/DATA/DIRECTORY"
});
The value for binDir
should be the path to the directory containing the BodyTrack Datastore's binary executables (export
, gettile
, import
, and info
). The value for dataDir
should be the path to the BodyTrack Datastore's data directory (typically named dev.kvs
).
For full documentation, generate the JSDocs:
npm run-script api-docs
You'll find the generated docs in the out
directory.