@file-services/types
Advanced tools
Comparing version 0.4.10 to 0.4.11
@@ -19,2 +19,15 @@ /// <reference types="node" /> | ||
/** | ||
* Get the current working directory. | ||
* Non-absolute calls to any file system method are resolved using this path. | ||
* | ||
* @returns absolute path to the current working directory. | ||
*/ | ||
cwd(): string; | ||
/** | ||
* Change the working directory. | ||
* | ||
* @directoryPath path to the new working directory. | ||
*/ | ||
chdir(directoryPath: string): void; | ||
/** | ||
* Copy `sourcePath` to `destinationPath`. | ||
@@ -57,2 +70,9 @@ * By default, if destination already exists, it will be overwritten. | ||
/** | ||
* Check if a path points to an existing file/directory/link. | ||
* | ||
* @param path possible file path. | ||
* @param statFn optional custom stat function (e.g. lstat to detect links). | ||
*/ | ||
existsSync(path: string): boolean; | ||
/** | ||
* Get path's `IFileSystemStats`. | ||
@@ -121,2 +141,9 @@ */ | ||
/** | ||
* Check if a path points to an existing file/directory/link. | ||
* | ||
* @param path possible file path. | ||
* @param statFn optional custom stat function (e.g. lstat to detect links). | ||
*/ | ||
exists(path: string): Promise<boolean>; | ||
/** | ||
* Get path's `IFileSystemStats`. | ||
@@ -123,0 +150,0 @@ */ |
{ | ||
"name": "@file-services/types", | ||
"description": "Common file system interfaces", | ||
"version": "0.4.10", | ||
"version": "0.4.11", | ||
"main": "cjs/index.js", | ||
@@ -25,3 +25,3 @@ "types": "cjs/index.d.ts", | ||
"sideEffects": false, | ||
"gitHead": "2c80218e713807c3ec965708c78e14af3433bcba" | ||
"gitHead": "d077e3795b175547ed2dbb821b90c12fbd29bcb5" | ||
} |
@@ -8,3 +8,3 @@ import { IWatchService } from './watch-api' | ||
*/ | ||
export interface IBaseFileSystem extends IBaseFileSystemAsync, IBaseFileSystemSync { } | ||
export interface IBaseFileSystem extends IBaseFileSystemAsync, IBaseFileSystemSync {} | ||
@@ -21,2 +21,17 @@ /** | ||
/** | ||
* Get the current working directory. | ||
* Non-absolute calls to any file system method are resolved using this path. | ||
* | ||
* @returns absolute path to the current working directory. | ||
*/ | ||
cwd(): string | ||
/** | ||
* Change the working directory. | ||
* | ||
* @directoryPath path to the new working directory. | ||
*/ | ||
chdir(directoryPath: string): void | ||
/** | ||
* Copy `sourcePath` to `destinationPath`. | ||
@@ -67,2 +82,10 @@ * By default, if destination already exists, it will be overwritten. | ||
/** | ||
* Check if a path points to an existing file/directory/link. | ||
* | ||
* @param path possible file path. | ||
* @param statFn optional custom stat function (e.g. lstat to detect links). | ||
*/ | ||
existsSync(path: string): boolean | ||
/** | ||
* Get path's `IFileSystemStats`. | ||
@@ -144,2 +167,10 @@ */ | ||
/** | ||
* Check if a path points to an existing file/directory/link. | ||
* | ||
* @param path possible file path. | ||
* @param statFn optional custom stat function (e.g. lstat to detect links). | ||
*/ | ||
exists(path: string): Promise<boolean> | ||
/** | ||
* Get path's `IFileSystemStats`. | ||
@@ -146,0 +177,0 @@ */ |
@@ -7,3 +7,3 @@ import { IBaseFileSystemAsync, IBaseFileSystemSync, IFileSystemStats } from './base-api' | ||
*/ | ||
export interface IFileSystem extends IFileSystemAsync, IFileSystemSync { } | ||
export interface IFileSystem extends IFileSystemAsync, IFileSystemSync {} | ||
@@ -10,0 +10,0 @@ /** |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
43937
985
9