Skip to content

Latest commit

 

History

History
39 lines (28 loc) · 1.28 KB

CONTRIBUTING.md

File metadata and controls

39 lines (28 loc) · 1.28 KB

Contributing to dd-native-metrics-js

Please reach out before starting work on any major code changes. This will ensure we avoid duplicating work, or that your code can't be merged due to a rapidly changing base. If you would like support for a module that is not listed, contact support to share a request.

Local setup

To set up the project locally, you can install it with:

$ npm install --ignore-scripts
$ node scripts/setup.js

The setup script will try to download libddwaf binaries with the GitHub CLI. If the GitHub CLI is not available you can always download the binaries manually from the libddwaf releases page, move it into a libddwaf folder and run the setup script again.

If libddwaf is in a private repository, you will need to set up an environment variable named GH_TOKEN with a Github token that has read access to libddwaf.

Download another release of libddwaf

The scripts/setup.js accepts the following environment variables:

  • PLATFORM: to override the value of os.platform()
  • ARCH: to override the value of os.arch()
  • LIBC: to select a specific libc implementaition (Linux only)

Build

Build the project with

$ npm run rebuild

and then it will be possible to run the tests with

$ npm t