memfs
Advanced tools
Comparing version 3.2.4 to 3.3.0
@@ -0,1 +1,14 @@ | ||
# [3.3.0](https://github.com/streamich/memfs/compare/v3.2.4...v3.3.0) (2021-09-19) | ||
### Bug Fixes | ||
* 🐛 remove unused method ([05b2a47](https://github.com/streamich/memfs/commit/05b2a472f75b46ce52a4730a8cd2d666a5deb196)) | ||
### Features | ||
* 🎸 add .rmSync(), .rm(), and .promises.rm() methods ([2414fb6](https://github.com/streamich/memfs/commit/2414fb6dae207536bf46120c4e09d8d51366a6c1)) | ||
* 🎸 add support for "recursive" and "force" flags in .rm() ([7f6714c](https://github.com/streamich/memfs/commit/7f6714cf14b90ce9cf50eeae517663b843687f90)) | ||
## [3.2.4](https://github.com/streamich/memfs/compare/v3.2.3...v3.2.4) (2021-09-02) | ||
@@ -2,0 +15,0 @@ |
/// <reference types="node" /> | ||
import { Volume, TData, TMode, TFlags, TFlagsCopy, TTime, IOptions, IAppendFileOptions, IMkdirOptions, IReaddirOptions, IReadFileOptions, IRealpathOptions, IWriteFileOptions, IStatOptions } from './volume'; | ||
import { Volume, TData, TMode, TFlags, TFlagsCopy, TTime, IOptions, IAppendFileOptions, IMkdirOptions, IReaddirOptions, IReadFileOptions, IRealpathOptions, IWriteFileOptions, IStatOptions, IRmOptions } from './volume'; | ||
import Stats from './Stats'; | ||
@@ -51,2 +51,3 @@ import Dirent from './Dirent'; | ||
rmdir(path: PathLike): Promise<void>; | ||
rm(path: PathLike, options?: IRmOptions): Promise<void>; | ||
stat(path: PathLike, options?: IStatOptions): Promise<Stats>; | ||
@@ -53,0 +54,0 @@ symlink(target: PathLike, path: PathLike, type?: symlink.Type): Promise<void>; |
@@ -135,2 +135,5 @@ "use strict"; | ||
}, | ||
rm: function (path, options) { | ||
return promisify(vol, 'rm')(path, options); | ||
}, | ||
stat: function (path, options) { | ||
@@ -137,0 +140,0 @@ return promisify(vol, 'stat')(path, options); |
@@ -91,2 +91,8 @@ /// <reference types="node" /> | ||
} | ||
export interface IRmOptions { | ||
force?: boolean; | ||
maxRetries?: number; | ||
recursive?: boolean; | ||
retryDelay?: number; | ||
} | ||
export interface IReaddirOptions extends IOptions { | ||
@@ -169,3 +175,5 @@ withFileTypes?: boolean; | ||
private getFileByFdOrThrow; | ||
private getNodeByIdOrCreate; | ||
/** | ||
* @todo This is not used anymore. Remove. | ||
*/ | ||
private wrapAsync; | ||
@@ -319,2 +327,6 @@ private _toJSON; | ||
rmdir(path: PathLike, options: IRmdirOptions, callback: TCallback<void>): any; | ||
private rmBase; | ||
rmSync(path: PathLike, options?: IRmOptions): void; | ||
rm(path: PathLike, callback: TCallback<void>): void; | ||
rm(path: PathLike, options: IRmOptions, callback: TCallback<void>): void; | ||
private fchmodBase; | ||
@@ -321,0 +333,0 @@ fchmodSync(fd: number, mode: TMode): void; |
{ | ||
"name": "memfs", | ||
"version": "3.2.4", | ||
"version": "3.3.0", | ||
"description": "In-memory file-system with Node's fs API.", | ||
@@ -33,4 +33,4 @@ "main": "lib/index.js", | ||
"husky": "7.0.2", | ||
"jest": "27.1.0", | ||
"prettier": "2.3.2", | ||
"jest": "27.2.0", | ||
"prettier": "2.4.1", | ||
"pretty-quick": "3.1.1", | ||
@@ -42,7 +42,7 @@ "rimraf": "3.0.2", | ||
"tslint-config-common": "1.6.0", | ||
"typescript": "4.4.2", | ||
"semantic-release": "17.4.7", | ||
"typescript": "4.4.3", | ||
"semantic-release": "18.0.0", | ||
"@semantic-release/changelog": "5.0.1", | ||
"@semantic-release/git": "9.0.0", | ||
"@semantic-release/npm": "7.1.3" | ||
"@semantic-release/git": "9.0.1", | ||
"@semantic-release/npm": "8.0.0" | ||
}, | ||
@@ -49,0 +49,0 @@ "config": { |
Sorry, the diff of this file is too big to display
192494
4337