![Build Status](https://camo.githubusercontent.com/e34db0b7b5b51b2fdbec1ad056fa92b958a8e0ffc1aeef9ef1d1dcdb05145ba9/68747470733a2f2f7472617669732d63692e6f72672f676f6273746f6e65732f676f6273746f6e65732d696e7465727072657465722e7376673f6272616e63683d6d6173746572)
// in node REPL
var Interpreter = require("./lib/gobstones-interpreter.js").GobstonesInterpreterAPI;
var interpreter = new Interpreter();
// parse
parseResult = interpreter.parse("program { Poner(Rojo) }");
// interpret
parseResult.program.interpret({
width: 2,
height: 2,
head: { x: 0, y: 0 },
table: [
[ { red: 0, blue: 0, green: 0, black: 0 }, {} ], // cells (0; 1) and (1; 1)
[ { blue: 0 }, { red: 0, black: 0 } ] // cells (0; 0) and (1; 0)
]
})
# put a new version number in package.json
# copy package.json from master to origin/bower
git checkout origin/bower
npm publish
npm install
- install the dependencies of the library
npm run build
- produces production version of your library under the lib
folder
npm run dev
- produces development version of your library and runs a watcher
npm run test
- well ... it runs the tests :)
npm run test:watch
- same as above but in a watch mode