(cwd = '.', name = 'zx', _ext?: string)
| 278 | |
| 279 | // prettier-ignore |
| 280 | function getFilepath(cwd = '.', name = 'zx', _ext?: string): string { |
| 281 | const ext = _ext || argv.ext || EXT |
| 282 | return [ |
| 283 | name + ext, |
| 284 | name + '-' + randomId() + ext, |
| 285 | ] |
| 286 | .map(f => path.resolve(process.cwd(), cwd, f)) |
| 287 | .find(f => !fs.existsSync(f))! |
| 288 | } |
no test coverage detected
searching dependent graphs…