Skip to content

Commit

Permalink
Merge pull request #698 from osiris43/master
Browse files Browse the repository at this point in the history
Fix for issue #673
  • Loading branch information
kpdecker committed Jan 3, 2014
2 parents 0c6829f + 70b27bc commit e9f3a16
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion tasks/parser.js
Expand Up @@ -4,7 +4,13 @@ module.exports = function(grunt) {
grunt.registerTask('parser', 'Generate jison parser.', function() {
var done = this.async();

var child = childProcess.spawn('./node_modules/.bin/jison', ['-m', 'js', 'src/handlebars.yy', 'src/handlebars.l'], {stdio: 'inherit'});
var cmd = './node_modules/.bin/jison';

if(process.platform === 'win32'){
cmd = 'node_modules\\.bin\\jison.cmd';
}

var child = childProcess.spawn(cmd, ['-m', 'js', 'src/handlebars.yy', 'src/handlebars.l'], {stdio: 'inherit'});
child.on('exit', function(code) {
if (code != 0) {
grunt.fatal('Jison failure: ' + code);
Expand Down

0 comments on commit e9f3a16

Please sign in to comment.