Skip to content

Latest commit

 

History

History
49 lines (28 loc) · 1.39 KB

CONTRIBUTING.md

File metadata and controls

49 lines (28 loc) · 1.39 KB

Contributing Code

Setup

To build highlightjs-cypher, you'll need the latest long term support (LTS) release of Node and npm. We recommend nvm to manage multiple active Node versions.

Start by cloning the source from GitHub:

$ git clone https://github.com/highlightjs/highlightjs-cypher.git

Next, install the dependencies using npm:

$ npm i

Test

To execute the tests, open a terminal and type:

$ npm t

Build the distribution

To generate the dist file, we need to clone the highlight.js main repository:

$ git clone https://github.com/highlightjs/highlight.js
$ cd highlight.js

Since the tooling is not yet merged on master (see highlightjs/highlight.js#2328), we need to checkout the squash_build_pipeline branch:

$ git checkout squash_build_pipeline

Then, install the dependencies:

$ npm i

Create an extra directory and clone the highlightjs-cypher repository in it:

$ mkdir extra
$ cd extra
$ git clone https://github.com/highlightjs/highlightjs-cypher
$ cd ..

Now we are ready to generate the dist file. Open a terminal and type:

$ node  --stack-size=65500  ./tools/build.js -t cdn

The generated file will be available in both build/languages/cypher.min.js and extra/highlightjs-cypher/dist/cypher.min.js.