mirror of
https://github.com/52north/ttn-ogcswe-integration
synced 2025-11-18 11:16:26 +01:00
1.8 KiB
1.8 KiB
ttn-ogcswe-integration developer guide
This project is written for node.js 6.x in TypeScript, which needs to be compiled
to javascript before running.
The source is managed using git flow, where features are developed on feature
branches and then pulled into the develop branch.
dev env setup
- Install the following dependencies:
- node.js 6.x or later: javascript runtime
- yarn: package manger & launcher
- git: source control
-
Follow the instructions under
Native InstallationinREADME.md. -
Register an application in TheThingsNetwork, and create a key for it. Insert the Application ID and the key into
config.yml. -
Set up an development instance of the storage backend you want to develop against. For the 52N SOS a docker image is defined in
docker/sos. Enter its address atbroker.options.hostinconfig.yml.
build cycle
- create a feature branch:
git checkout develop && git checkout -b feature/myfeature - launch your storage backend and make sure
config.ymlcorrectly points to it - run
yarn build:watchto start the build process on each source change. - Make changes in
src/**. - (re)start the application with
yarn startand test.- to do end to end tests without a LoRa device, you can simulate TTN uplink
messages at the device view in
console.thethingsnetwork.orgor using ttnctl.
- to do end to end tests without a LoRa device, you can simulate TTN uplink
messages at the device view in
- repeat from step 4 until a (sub)feature is working/fixed.
- lint the code using
yarn lintand fix errors as suggested. - commit using
git commit - create a pull request on github to
develop.
Please make sure your code fits the style of the existing codebase, and verify
with yarn lint before committing.