@rnm/pm
Version:
Unified Package Manager for Node.js
18 lines • 747 B
TypeScript
export type SupportedPm = "npm" | "yarn" | "pnpm";
export interface DetectResult {
name: SupportedPm;
version?: string;
}
export declare const executorMap: {
readonly npm: "npx";
readonly yarn: "yarnpkg";
readonly pnpm: "pnpx";
};
/**
* Detects the package manager used in the specified directory.
* @param directory - The absolute path to the directory to check.
*/
export declare function detect(directory?: string): Promise<DetectResult | undefined>;
export declare function run(detectResult: DetectResult | undefined, args: string[], execute?: boolean): Promise<number>;
export declare function getMsg(detectResult: DetectResult | undefined, args: string[], execute?: boolean): string;
//# sourceMappingURL=base.d.ts.map