@socketsecurity/lib
Version:
Core utilities and infrastructure for Socket.dev security tools
18 lines (17 loc) • 745 B
TypeScript
export interface ShadowInstallationOptions {
cwd?: string | undefined;
win32?: boolean | undefined;
}
/**
* Determines if shadow binaries should be installed.
* Shadows should NOT be installed when:
* - Running in a temporary execution context (exec/npx/dlx)
* - On Windows with an existing binary path (required for Windows to function)
*
* @param binPath - Path to the binary being shadowed
* @param options - Configuration options
* @param options.cwd - Current working directory path to check
* @param options.win32 - Whether running on Windows
* @returns true if shadow installation should be skipped
*/
export declare function shouldSkipShadow(binPath: string, options?: ShadowInstallationOptions | undefined): boolean;