Skip to content

Instantly share code, notes, and snippets.

@TooTallNate
Created August 13, 2012 19:29
Show Gist options
  • Save TooTallNate/3343487 to your computer and use it in GitHub Desktop.
Save TooTallNate/3343487 to your computer and use it in GitHub Desktop.
Using node-gyp programmatically. This could be made better...
var Gyp = require('node-gyp')
var gyp = Gyp()
gyp.parseArgv([])
// run "clean", "configure", then "build"
gyp.commands.clean([], function (err) {
console.error('clean', arguments);
gyp.commands.configure([], function (err) {
if (err) throw err;
console.error('configure', arguments);
gyp.commands.build([], function (err) {
if (err) throw err;
console.error('build', arguments);
});
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment