马宇豪
2024-08-21 d972ec93c21ee8cc62fd514bfd910192eeaf48d8
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'