@pnpm/link-bins
Version:
Link bins to node_modules/.bin
26 lines (25 loc) • 1.1 kB
TypeScript
import { type DependencyManifest, type ProjectManifest } from '@pnpm/types';
export type WarningCode = 'BINARIES_CONFLICT' | 'EMPTY_BIN';
export type WarnFunction = (msg: string, code: WarningCode) => void;
export declare function linkBins(modulesDir: string, binsDir: string, opts: LinkBinOptions & {
allowExoticManifests?: boolean;
nodeExecPathByAlias?: Record<string, string>;
projectManifest?: ProjectManifest;
warn: WarnFunction;
}): Promise<string[]>;
export declare function linkBinsOfPkgsByAliases(depsAliases: string[], binsDir: string, opts: LinkBinOptions & {
modulesDir: string;
allowExoticManifests?: boolean;
nodeExecPathByAlias?: Record<string, string>;
projectManifest?: ProjectManifest;
warn: WarnFunction;
}): Promise<string[]>;
export declare function linkBinsOfPackages(pkgs: Array<{
manifest: DependencyManifest;
nodeExecPath?: string;
location: string;
}>, binsTarget: string, opts?: LinkBinOptions): Promise<string[]>;
export interface LinkBinOptions {
extraNodePaths?: string[];
preferSymlinkedExecutables?: boolean;
}