TheThingsNetwork / lorawan-stack

The Things Stack, an Open Source LoRaWAN Network Server
https://www.thethingsindustries.com/stack/
Apache License 2.0
957 stars 302 forks source link

Introduce a development JS package at /tools #2769

Open rvolosatovs opened 4 years ago

rvolosatovs commented 4 years ago

Summary

Extract all development dependencies to /tools, same as we do for Go.

Why do we need this?

  1. The same tools are vendored and installed twice currently - if we only do it once: a. Less maintenance required (only one tool version to maintain) b. Faster builds and CI c. Less space required on disk
  2. Root module depends on JS SDK, hence we need to build the JS SDK before we even start resolving depencies in the root module - that makes no sense and e.g. in CI means that we have to resolve JS SDK dependencies, then build JS SDK, then resolve root module depencies and only then we can e.g. run version:files
  3. Simpler build process, since then we can just run all commands from the same directory.

What is already there? What do you see now?

Currently we have a JS package at root and JS package at js/sdk vendoring the same tools.

What is missing? What do you want to see?

Node package at tools module, which vendors all the development-related dependencies.

Environment

All, especially CI

How do you propose to implement this?

  1. Introduce tools package
  2. Move all dev tools there
  3. Fix mage stuff

How do you propose to test this?

CI, locally run mage

Can you do this yourself and submit a Pull Request?

yes

johanstokking commented 4 years ago

Candidate issue for new hire