@jjeem/detect-shell
Version:
detect shells available on the system
20 lines (19 loc) • 816 B
TypeScript
/// <reference types="node" />
/// <reference types="node" />
import fs from 'fs';
export declare function readFile(path: string): Promise<Buffer>;
export declare function readFile(path: string, encoding: BufferEncoding): Promise<string>;
export declare function stat(path: string): Promise<fs.Stats>;
export declare function lstat(path: string): Promise<fs.Stats>;
export declare function readlink(path: string): Promise<string>;
export declare function readdir(path: string): Promise<string[]>;
export declare function dirExists(path: string): Promise<boolean>;
export declare function fileExists(path: string): Promise<boolean>;
export declare function statLink(path: string): Promise<IStatAndLink>;
interface IStatAndLink {
stat: fs.Stats;
symbolicLink?: {
dangling: boolean;
};
}
export {};