Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
grammar.y -> grammar.json
JavaScript
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
.gitignore init
README.md init
jison2json.js init
package.json 0.0.2
tests.js init

README.md

jison2json

jison grammars come in two formats: JSON or a speciel text format similar to Bison's. This utility converts from the jison's format to JSON. See the json2jison for the reverse conversion.

install

npm install jison2json -g

usage

# single grammar
jison2json grammar.y

# or separate grammars
jison2json grammar.y lex.l

Or require it and convert programatically:

var jison2json = require('jison2json');
var grammar = "%% foo: bar { return true };";

var json = jison2json.convert(grammar);

license

MIT

Something went wrong with that request. Please try again.