1 | import { Interfaces } from '@oclif/core';
|
2 | import { LogLevel } from './log-level.js';
|
3 | import { ExecOptions, Output } from './spawn.js';
|
4 | type InstallOptions = {
|
5 | prod?: boolean;
|
6 | } & ExecOptions;
|
7 | export declare class NPM {
|
8 | private bin;
|
9 | private config;
|
10 | private logLevel;
|
11 | constructor({ config, logLevel }: {
|
12 | config: Interfaces.Config;
|
13 | logLevel: LogLevel;
|
14 | });
|
15 | exec(args: string[] | undefined, options: ExecOptions): Promise<Output>;
|
16 | install(args: string[], opts: InstallOptions): Promise<Output>;
|
17 | uninstall(args: string[], opts: ExecOptions): Promise<Output>;
|
18 | update(args: string[], opts: ExecOptions): Promise<Output>;
|
19 | view(args: string[], opts: ExecOptions): Promise<Output>;
|
20 | /**
|
21 | * Get the path to the npm CLI file.
|
22 | * This will resolve npm to the pinned version in `@oclif/plugin-plugins/package.json` if it exists.
|
23 | * Otherwise, it will use the globally installed npm.
|
24 | *
|
25 | * @returns The path to the `npm/bin/npm-cli.js` file.
|
26 | */
|
27 | private findNpm;
|
28 | }
|
29 | export {};
|