@@ -3533,9 +3533,9 @@ changes:
35333533* ` options ` {Object}
35343534 * ` maxRetries ` {integer} If an ` EBUSY ` , ` EMFILE ` , ` ENFILE ` , ` ENOTEMPTY ` , or
35353535 ` EPERM ` error is encountered, Node.js will retry the operation with a linear
3536- backoff wait of ` retryDelay ` ms longer on each try. This option represents
3537- the number of retries. This option is ignored if the ` recursive ` option is
3538- not ` true ` . ** Default:** ` 0 ` .
3536+ backoff wait of ` retryDelay ` milliseconds longer on each try. This option
3537+ represents the number of retries. This option is ignored if the ` recursive `
3538+ option is not ` true ` . ** Default:** ` 0 ` .
35393539 * ` recursive ` {boolean} If ` true ` , perform a recursive directory removal. In
35403540 recursive mode, errors are not reported if ` path ` does not exist, and
35413541 operations are retried on failure. ** Default:** ` false ` .
@@ -3584,9 +3584,9 @@ changes:
35843584* ` options ` {Object}
35853585 * ` maxRetries ` {integer} If an ` EBUSY ` , ` EMFILE ` , ` ENFILE ` , ` ENOTEMPTY ` , or
35863586 ` EPERM ` error is encountered, Node.js will retry the operation with a linear
3587- backoff wait of ` retryDelay ` ms longer on each try. This option represents
3588- the number of retries. This option is ignored if the ` recursive ` option is
3589- not ` true ` . ** Default:** ` 0 ` .
3587+ backoff wait of ` retryDelay ` milliseconds longer on each try. This option
3588+ represents the number of retries. This option is ignored if the ` recursive `
3589+ option is not ` true ` . ** Default:** ` 0 ` .
35903590 * ` recursive ` {boolean} If ` true ` , perform a recursive directory removal. In
35913591 recursive mode, errors are not reported if ` path ` does not exist, and
35923592 operations are retried on failure. ** Default:** ` false ` .
@@ -3605,6 +3605,53 @@ that represent files will be deleted. The permissive behavior of the
36053605` recursive ` option is deprecated, ` ENOTDIR ` and ` ENOENT ` will be thrown in
36063606the future.
36073607
3608+ ## ` fs.rm(path[, options], callback) `
3609+ <!-- YAML
3610+ added: REPLACEME
3611+ -->
3612+
3613+ * ` path ` {string|Buffer|URL}
3614+ * ` options ` {Object}
3615+ * ` force ` don't error on nonexistent path
3616+ * ` maxRetries ` {integer} If an ` EBUSY ` , ` EMFILE ` , ` ENFILE ` , ` ENOTEMPTY ` , or
3617+ ` EPERM ` error is encountered, Node.js will retry the operation with a linear
3618+ backoff wait of ` retryDelay ` milliseconds longer on each try. This option
3619+ represents the number of retries. This option is ignored if the ` recursive `
3620+ option is not ` true ` . ** Default:** ` 0 ` .
3621+ * ` recursive ` {boolean} If ` true ` , perform a recursive removal. In
3622+ recursive mode operations are retried on failure. ** Default:** ` false ` .
3623+ * ` retryDelay ` {integer} The amount of time in milliseconds to wait between
3624+ retries. This option is ignored if the ` recursive ` option is not ` true ` .
3625+ ** Default:** ` 100 ` .
3626+ * ` callback ` {Function}
3627+ * ` err ` {Error}
3628+
3629+ Asynchronously removes files and directories (modeled on the standard POSIX ` rm `
3630+ utility). No arguments other than a possible exception are given to the
3631+ completion callback.
3632+
3633+ ## ` fs.rmSync(path[, options]) `
3634+ <!-- YAML
3635+ added: REPLACEME
3636+ -->
3637+
3638+ * ` path ` {string|Buffer|URL}
3639+ * ` options ` {Object}
3640+ * ` force ` Ignore errors
3641+ * ` maxRetries ` {integer} If an ` EBUSY ` , ` EMFILE ` , ` ENFILE ` , ` ENOTEMPTY ` , or
3642+ ` EPERM ` error is encountered, Node.js will retry the operation with a linear
3643+ backoff wait of ` retryDelay ` milliseconds longer on each try. This option
3644+ represents the number of retries. This option is ignored if the ` recursive `
3645+ option is not ` true ` . ** Default:** ` 0 ` .
3646+ * ` recursive ` {boolean} If ` true ` , perform a recursive directory removal. In
3647+ recursive mode operations are retried on failure. ** Default:** ` false ` .
3648+ * ` retryDelay ` {integer} The amount of time in milliseconds to wait between
3649+ retries. This option is ignored if the ` recursive ` option is not ` true ` .
3650+ ** Default:** ` 100 ` .
3651+
3652+ Synchronously removes files and directories (modeled on the standard POSIX ` rm `
3653+ utility). Returns ` undefined ` .
3654+
36083655## ` fs.stat(path[, options], callback) `
36093656<!-- YAML
36103657added: v0.0.2
@@ -5477,9 +5524,9 @@ changes:
54775524* ` options ` {Object}
54785525 * ` maxRetries ` {integer} If an ` EBUSY ` , ` EMFILE ` , ` ENFILE ` , ` ENOTEMPTY ` , or
54795526 ` EPERM ` error is encountered, Node.js will retry the operation with a linear
5480- backoff wait of ` retryDelay ` ms longer on each try. This option represents
5481- the number of retries. This option is ignored if the ` recursive ` option is
5482- not ` true ` . ** Default:** ` 0 ` .
5527+ backoff wait of ` retryDelay ` milliseconds longer on each try. This option
5528+ represents the number of retries. This option is ignored if the ` recursive `
5529+ option is not ` true ` . ** Default:** ` 0 ` .
54835530 * ` recursive ` {boolean} If ` true ` , perform a recursive directory removal. In
54845531 recursive mode, errors are not reported if ` path ` does not exist, and
54855532 operations are retried on failure. ** Default:** ` false ` .
@@ -5501,6 +5548,28 @@ that represent files will be deleted. The permissive behavior of the
55015548` recursive ` option is deprecated, ` ENOTDIR ` and ` ENOENT ` will be thrown in
55025549the future.
55035550
5551+ ## ` fsPromises.rm(path[, options]) `
5552+ <!-- YAML
5553+ added: REPLACEME
5554+ -->
5555+
5556+ * ` path ` {string|Buffer|URL}
5557+ * ` options ` {Object}
5558+ * ` force ` Ignore errors
5559+ * ` maxRetries ` {integer} If an ` EBUSY ` , ` EMFILE ` , ` ENFILE ` , ` ENOTEMPTY ` , or
5560+ ` EPERM ` error is encountered, Node.js will retry the operation with a linear
5561+ backoff wait of ` retryDelay ` milliseconds longer on each try. This option
5562+ represents the number of retries. This option is ignored if the ` recursive `
5563+ option is not ` true ` . ** Default:** ` 0 ` .
5564+ * ` recursive ` {boolean} If ` true ` , perform a recursive directory removal. In
5565+ recursive mode operations are retried on failure. ** Default:** ` false ` .
5566+ * ` retryDelay ` {integer} The amount of time in milliseconds to wait between
5567+ retries. This option is ignored if the ` recursive ` option is not ` true ` .
5568+ ** Default:** ` 100 ` .
5569+
5570+ Synchronously removes files and directories (modeled on the standard POSIX ` rm `
5571+ utility). Resolves the ` Promise ` with no arguments on success.
5572+
55045573### ` fsPromises.stat(path[, options]) `
55055574<!-- YAML
55065575added: v10.0.0
0 commit comments