riboseinc / ribose-api

API for Ribose
0 stars 0 forks source link

Improve build tools #49

Closed skalee closed 7 years ago

skalee commented 7 years ago

Right now we rely on:

  1. A makefile, which manages blueprint compilation (runs Hercule when needed)
  2. A Hercule, which actually couples blueprint sections together, and is an NPM tool
  3. A validator implemented in JavaScript, and run in Node.js environment
  4. A Bash script, which ensures that apiary.apib is up-to-date
  5. Some not-yet-known tool which removes comments from compiled blueprints.

That's pretty complicated., and bound to *nix platform. Furthermore, In my attempt to rewrite a README (#27) I've realized that prerequisite steps recently became pretty difficult to describe, and probably discouraging to contributors.

My suggestion is to:

  1. Introduce a package.json which would maintain dependencies. Currently all the dependencies, apart from Git, are actually NPM packages.
  2. NPM is also a build tool, we can create custom scripts which run Hercule or perform validations. In the result, we can remove a makefile.
  3. A Bash script is only needed in CI, so it doesn't need to be cross-platform.
skalee commented 7 years ago

I guess I'll do it at least as a proof of concept. It will likely make fixing #36 and #19 easier.

skalee commented 7 years ago

IMO we can consider it done.