node/deps/npm/node_modules/node-gyp/lib/clean.js

23 lines
378 B
JavaScript
Raw Normal View History

module.exports = exports = clean
exports.usage = 'Removes any generated build files and the "out" dir'
/**
* Module dependencies.
*/
var rm = require('rimraf')
2012-06-16 01:00:30 +08:00
var log = require('npmlog')
function clean (gyp, argv, callback) {
// Remove the 'build' dir
var buildDir = 'build'
2012-04-18 08:14:25 +08:00
2012-06-16 01:00:30 +08:00
log.verbose('clean', 'removing "%s" directory', buildDir)
2012-04-18 08:14:25 +08:00
rm(buildDir, callback)
}