UNPKG

projen

Version:

CDK for software projects

24 lines (23 loc) 1.19 kB
/** * Installs the npm module (through `npm install`) to node_modules under `projectDir`. * @param spec The npm package spec (e.g. `foo@^1.2` or `foo@/var/folders/8k/qcw0ls5pv_ph0000gn/T/projen-RYurCw/pkg.tgz`) * @returns The installed package name (e.g. `@foo/bar`) */ export declare function installPackage(baseDir: string, spec: string, isProjen?: boolean): Promise<string>; /** * Render the arguments to install an npm package (the args following `npm`). * * Engine checks are ignored at this point so that the module can be installed * regardless of the environment. This was needed to unblock the upgrade of the * minimum node version of projen, but also okay generally because engine checks * will be performed later and for all eternity. * * @param dir Base directory * @param module The module to install (e.g. foo@^1.2) * @returns The arguments for `npm` (e.g. ["install", ..., "foo@^1.2"]) */ export declare function renderInstallArgs(dir: string, module: string): string[]; export declare function findJsiiFilePath(baseDir: string, moduleName: string): string | undefined; export declare class CliError extends Error { constructor(...lines: string[]); }