-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Expand file tree
/
Copy pathnpm-auth-refresh.d.mts
More file actions
39 lines (36 loc) · 1.4 KB
/
Copy pathnpm-auth-refresh.d.mts
File metadata and controls
39 lines (36 loc) · 1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------------------------------------------*/
export interface AuthCommand {
command: string;
args: string[];
cwd?: string;
}
export type ConfigWriter = (npmrcPaths: string[]) => void;
export type CommandRunner = (
command: string,
args: string[],
platform: string,
cwd?: string
) => void;
export type AuthRefresher = () => void;
export const azureFeedLocalRegistry: string;
export const cfsRegistry: string;
export const credentialProviderRegistry: string;
export function getProjectNpmrcPaths(scriptUrl?: string): string[];
export function buildProjectNpmConfig(existingConfig?: string): string;
export function writeProjectNpmConfigs(npmrcPaths: string[]): void;
export function getAuthCommands(platform: string, npmrcPath: string): AuthCommand[];
export function getCommandInvocation(
platform: string,
command: string,
args: string[]
): AuthCommand;
export function runCommand(command: string, args: string[], platform?: string, cwd?: string): void;
export function refreshNpmAuthentication(
platform?: string,
npmrcPaths?: string[],
writer?: ConfigWriter,
runner?: CommandRunner
): void;
export function main(args?: string[], refresh?: AuthRefresher): number;