UNPKG

@stryke/fs

Version:

A package containing various file system utilities that expand the functionality of NodeJs's built-in `fs` module.

19 lines (18 loc) 842 B
/** * Asynchronously checks if a command exists in the system. * * @remarks * This function will check if the command is available in the system's PATH and if it is executable. * @param commandName - The name of the command to check for existence * @returns A promise that resolves to `true` if the command exists and is executable, `false` otherwise */ export declare function commandExists(commandName: string): Promise<void>; /** * Synchronously checks if a command exists in the system. * * @remarks * This function will check if the command is available in the system's PATH and if it is executable. * @param commandName - The name of the command to check for existence * @returns `true` if the command exists and is executable, `false` otherwise */ export declare function commandExistsSync(commandName: string): boolean;