• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// only remove the thing if it's a symlink into a specific folder. This is
2// a very common use-case of npm's, but not so common elsewhere.
3
4exports = module.exports = gentlyRm
5
6var gentleFS = require('gentle-fs')
7var gentleFSOpts = require('../config/gentle-fs.js')
8
9function gentlyRm (target, gently, base, cb) {
10  if (!cb) {
11    cb = base
12    base = undefined
13  }
14
15  if (!cb) {
16    cb = gently
17    gently = false
18  }
19
20  return gentleFS.rm(target, gentleFSOpts(gently, base), cb)
21}
22