马宇豪
2024-07-16 f591c27b57e2418c9495bc02ae8cfff84d35bc18
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
'use strict'
 
const fs = require('graceful-fs').promises
const log = require('./log')
 
async function clean (gyp, argv) {
  // Remove the 'build' dir
  const buildDir = 'build'
 
  log.verbose('clean', 'removing "%s" directory', buildDir)
  await fs.rm(buildDir, { recursive: true, force: true })
}
 
module.exports = clean
module.exports.usage = 'Removes any generated build files and the "out" dir'