3.0.0 • Published 7 years ago

ocamlBetterErrors v3.0.0

Weekly downloads
50
License
-
Repository
github
Last release
7 years ago

Before

Before

After

Glorious After

Before

Before

After

Glorious After

Work in progress!

npm install -g ocamlBetterErrors

Put this in your project's package.json:

{
  "scripts": {
    "start": "eval $(dependencyEnv) && nopam && which berror.native"
  },
  "dependencies": {
    "nopam": "*",
    "dependency-env": "*",
    "ocamlBetterErrors": "*"
  }
}

Running npm start with such configuration will expose the berror.native binary, for you to use like so:

ocamlc myApp.ml |& berror.native

Explanation: |& is a bash shortcut for 2>&1 | (not available in vanilla sh), which, in turn, means "pipe the stuff from stderr into stdout, then pipe it back into stdin of the next command". berror takes in this info and searches for errors to pretty-print back.

To format the output in Reason syntax, use berror --path-to-refmttype thePathToRefmttype (where refmttype is a binary exposed by Reason).

Have fun!

For Development

git clone this repo, cd into it, then run:

npm install
# to compile
npm start
# to test, currently broken
npm test
3.0.0

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.10

8 years ago

0.0.9

8 years ago

0.0.8

8 years ago

0.0.7

8 years ago

0.0.6

8 years ago

0.0.5

8 years ago

0.0.3

8 years ago

0.0.2

8 years ago

0.0.1

8 years ago