@codingame/monaco-vscode-rollup-vsix-plugin 1.83.13 → 1.83.15-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/vscode-dts/vscode.proposed.aiRelatedInformation.d.ts +49 -0
- package/vscode-dts/vscode.proposed.authGetSessions.d.ts +62 -0
- package/vscode-dts/vscode.proposed.authSession.d.ts +13 -0
- package/vscode-dts/vscode.proposed.canonicalUriProvider.d.ts +47 -0
- package/vscode-dts/vscode.proposed.chat.d.ts +25 -0
- package/vscode-dts/vscode.proposed.chatAgents.d.ts +39 -0
- package/vscode-dts/vscode.proposed.chatProvider.d.ts +38 -0
- package/vscode-dts/vscode.proposed.chatRequestAccess.d.ts +47 -0
- package/vscode-dts/vscode.proposed.chatSlashCommands.d.ts +47 -0
- package/vscode-dts/vscode.proposed.chatVariables.d.ts +35 -0
- package/vscode-dts/vscode.proposed.codiconDecoration.d.ts +48 -0
- package/vscode-dts/vscode.proposed.commentsDraftState.d.ts +18 -0
- package/vscode-dts/vscode.proposed.contribCommentEditorActionsMenu.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribCommentPeekContext.d.ts +10 -0
- package/vscode-dts/vscode.proposed.contribCommentThreadAdditionalMenu.d.ts +8 -0
- package/vscode-dts/vscode.proposed.contribEditSessions.d.ts +8 -0
- package/vscode-dts/vscode.proposed.contribEditorContentMenu.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribLabelFormatterWorkspaceTooltip.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribMenuBarHome.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribMergeEditorMenus.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribNotebookStaticPreloads.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribRemoteHelp.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribShareMenu.d.ts +7 -0
- package/vscode-dts/vscode.proposed.contribStatusBarItems.d.ts +8 -0
- package/vscode-dts/vscode.proposed.contribViewsRemote.d.ts +6 -0
- package/vscode-dts/vscode.proposed.contribViewsWelcome.d.ts +6 -0
- package/vscode-dts/vscode.proposed.customEditorMove.d.ts +29 -0
- package/vscode-dts/vscode.proposed.debugFocus.d.ts +74 -0
- package/vscode-dts/vscode.proposed.diffCommand.d.ts +38 -0
- package/vscode-dts/vscode.proposed.diffContentOptions.d.ts +16 -0
- package/vscode-dts/vscode.proposed.documentFiltersExclusive.d.ts +13 -0
- package/vscode-dts/vscode.proposed.documentPaste.d.ts +111 -0
- package/vscode-dts/vscode.proposed.dropMetadata.d.ts +60 -0
- package/vscode-dts/vscode.proposed.editSessionIdentityProvider.d.ts +71 -0
- package/vscode-dts/vscode.proposed.editorInsets.d.ts +22 -0
- package/vscode-dts/vscode.proposed.extensionRuntime.d.ts +24 -0
- package/vscode-dts/vscode.proposed.extensionsAny.d.ts +40 -0
- package/vscode-dts/vscode.proposed.externalUriOpener.d.ts +163 -0
- package/vscode-dts/vscode.proposed.fileComments.d.ts +85 -0
- package/vscode-dts/vscode.proposed.fileSearchProvider.d.ts +67 -0
- package/vscode-dts/vscode.proposed.findTextInFiles.d.ts +104 -0
- package/vscode-dts/vscode.proposed.fsChunks.d.ts +16 -0
- package/vscode-dts/vscode.proposed.handleIssueUri.d.ts +31 -0
- package/vscode-dts/vscode.proposed.idToken.d.ts +16 -0
- package/vscode-dts/vscode.proposed.inlineCompletionsAdditions.d.ts +71 -0
- package/vscode-dts/vscode.proposed.interactive.d.ts +227 -0
- package/vscode-dts/vscode.proposed.interactiveUserActions.d.ts +70 -0
- package/vscode-dts/vscode.proposed.interactiveWindow.d.ts +25 -0
- package/vscode-dts/vscode.proposed.ipc.d.ts +37 -0
- package/vscode-dts/vscode.proposed.mappedEditsProvider.d.ts +42 -0
- package/vscode-dts/vscode.proposed.notebookCellExecutionState.d.ts +52 -0
- package/vscode-dts/vscode.proposed.notebookControllerAffinityHidden.d.ts +17 -0
- package/vscode-dts/vscode.proposed.notebookDeprecated.d.ts +16 -0
- package/vscode-dts/vscode.proposed.notebookExecution.d.ts +39 -0
- package/vscode-dts/vscode.proposed.notebookKernelSource.d.ts +46 -0
- package/vscode-dts/vscode.proposed.notebookLiveShare.d.ts +21 -0
- package/vscode-dts/vscode.proposed.notebookMessaging.d.ts +68 -0
- package/vscode-dts/vscode.proposed.notebookMime.d.ts +33 -0
- package/vscode-dts/vscode.proposed.portsAttributes.d.ts +100 -0
- package/vscode-dts/vscode.proposed.profileContentHandlers.d.ts +19 -0
- package/vscode-dts/vscode.proposed.quickDiffProvider.d.ts +17 -0
- package/vscode-dts/vscode.proposed.quickPickItemTooltip.d.ts +16 -0
- package/vscode-dts/vscode.proposed.quickPickSortByLabel.d.ts +16 -0
- package/vscode-dts/vscode.proposed.readonlyMessage.d.ts +14 -0
- package/vscode-dts/vscode.proposed.resolvers.d.ts +371 -0
- package/vscode-dts/vscode.proposed.saveEditor.d.ts +35 -0
- package/vscode-dts/vscode.proposed.scmActionButton.d.ts +19 -0
- package/vscode-dts/vscode.proposed.scmHistoryProvider.d.ts +77 -0
- package/vscode-dts/vscode.proposed.scmSelectedProvider.d.ts +22 -0
- package/vscode-dts/vscode.proposed.scmTextDocument.d.ts +19 -0
- package/vscode-dts/vscode.proposed.scmValidation.d.ts +60 -0
- package/vscode-dts/vscode.proposed.shareProvider.d.ts +74 -0
- package/vscode-dts/vscode.proposed.showLocal.d.ts +19 -0
- package/vscode-dts/vscode.proposed.tabInputTextMerge.d.ts +25 -0
- package/vscode-dts/vscode.proposed.taskPresentationGroup.d.ts +16 -0
- package/vscode-dts/vscode.proposed.telemetry.d.ts +36 -0
- package/vscode-dts/vscode.proposed.terminalDataWriteEvent.d.ts +32 -0
- package/vscode-dts/vscode.proposed.terminalDimensions.d.ts +39 -0
- package/vscode-dts/vscode.proposed.terminalExecuteCommandEvent.d.ts +46 -0
- package/vscode-dts/vscode.proposed.terminalQuickFixProvider.d.ts +83 -0
- package/vscode-dts/vscode.proposed.terminalSelection.d.ts +16 -0
- package/vscode-dts/vscode.proposed.testCoverage.d.ts +198 -0
- package/vscode-dts/vscode.proposed.testMessageContextValue.d.ts +45 -0
- package/vscode-dts/vscode.proposed.testObserver.d.ts +184 -0
- package/vscode-dts/vscode.proposed.textSearchProvider.d.ts +281 -0
- package/vscode-dts/vscode.proposed.timeline.d.ts +163 -0
- package/vscode-dts/vscode.proposed.tokenInformation.d.ts +26 -0
- package/vscode-dts/vscode.proposed.treeViewActiveItem.d.ts +30 -0
- package/vscode-dts/vscode.proposed.treeViewMarkdownMessage.d.ts +28 -0
- package/vscode-dts/vscode.proposed.treeViewReveal.d.ts +13 -0
- package/vscode-dts/vscode.proposed.tunnelFactory.d.ts +44 -0
- package/vscode-dts/vscode.proposed.tunnels.d.ts +64 -0
- package/vscode-dts/vscode.proposed.windowActivity.d.ts +17 -0
- package/vscode-dts/vscode.proposed.workspaceTrust.d.ts +30 -0
- package/vscode.proposed.d.ts +0 -4787
|
@@ -0,0 +1,371 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
declare module 'vscode' {
|
|
7
|
+
|
|
8
|
+
//resolvers: @alexdima
|
|
9
|
+
|
|
10
|
+
export interface MessageOptions {
|
|
11
|
+
/**
|
|
12
|
+
* Do not render a native message box.
|
|
13
|
+
*/
|
|
14
|
+
useCustom?: boolean;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export interface RemoteAuthorityResolverContext {
|
|
18
|
+
resolveAttempt: number;
|
|
19
|
+
/**
|
|
20
|
+
* Exec server from a recursively-resolved remote authority. If the
|
|
21
|
+
* remote authority includes nested authorities delimited by `@`, it is
|
|
22
|
+
* resolved from outer to inner authorities with ExecServer passed down
|
|
23
|
+
* to each resolver in the chain.
|
|
24
|
+
*/
|
|
25
|
+
execServer?: ExecServer;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export class ResolvedAuthority {
|
|
29
|
+
readonly host: string;
|
|
30
|
+
readonly port: number;
|
|
31
|
+
readonly connectionToken: string | undefined;
|
|
32
|
+
|
|
33
|
+
constructor(host: string, port: number, connectionToken?: string);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface ManagedMessagePassing {
|
|
37
|
+
onDidReceiveMessage: Event<Uint8Array>;
|
|
38
|
+
onDidClose: Event<Error | undefined>;
|
|
39
|
+
onDidEnd: Event<void>;
|
|
40
|
+
|
|
41
|
+
send: (data: Uint8Array) => void;
|
|
42
|
+
end: () => void;
|
|
43
|
+
drain?: () => Thenable<void>;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export class ManagedResolvedAuthority {
|
|
47
|
+
readonly makeConnection: () => Thenable<ManagedMessagePassing>;
|
|
48
|
+
readonly connectionToken: string | undefined;
|
|
49
|
+
|
|
50
|
+
constructor(makeConnection: () => Thenable<ManagedMessagePassing>, connectionToken?: string);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export interface ResolvedOptions {
|
|
54
|
+
extensionHostEnv?: { [key: string]: string | null };
|
|
55
|
+
|
|
56
|
+
isTrusted?: boolean;
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* When provided, remote server will be initialized with the extensions synced using the given user account.
|
|
60
|
+
*/
|
|
61
|
+
authenticationSessionForInitializingExtensions?: AuthenticationSession & { providerId: string };
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export interface TunnelPrivacy {
|
|
65
|
+
themeIcon: string;
|
|
66
|
+
id: string;
|
|
67
|
+
label: string;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export namespace env {
|
|
71
|
+
/** Quality of the application. May be undefined if running from sources. */
|
|
72
|
+
export const appQuality: string | undefined;
|
|
73
|
+
/** Commit of the application. May be undefined if running from sources. */
|
|
74
|
+
export const appCommit: string | undefined;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
interface TunnelOptions {
|
|
78
|
+
remoteAddress: { port: number; host: string };
|
|
79
|
+
// The desired local port. If this port can't be used, then another will be chosen.
|
|
80
|
+
localAddressPort?: number;
|
|
81
|
+
label?: string;
|
|
82
|
+
/**
|
|
83
|
+
* @deprecated Use privacy instead
|
|
84
|
+
*/
|
|
85
|
+
public?: boolean;
|
|
86
|
+
privacy?: string;
|
|
87
|
+
protocol?: string;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
interface TunnelDescription {
|
|
91
|
+
remoteAddress: { port: number; host: string };
|
|
92
|
+
//The complete local address(ex. localhost:1234)
|
|
93
|
+
localAddress: { port: number; host: string } | string;
|
|
94
|
+
/**
|
|
95
|
+
* @deprecated Use privacy instead
|
|
96
|
+
*/
|
|
97
|
+
public?: boolean;
|
|
98
|
+
privacy?: string;
|
|
99
|
+
// If protocol is not provided it is assumed to be http, regardless of the localAddress.
|
|
100
|
+
protocol?: string;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
interface Tunnel extends TunnelDescription {
|
|
104
|
+
// Implementers of Tunnel should fire onDidDispose when dispose is called.
|
|
105
|
+
onDidDispose: Event<void>;
|
|
106
|
+
dispose(): void | Thenable<void>;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Used as part of the ResolverResult if the extension has any candidate,
|
|
111
|
+
* published, or forwarded ports.
|
|
112
|
+
*/
|
|
113
|
+
export interface TunnelInformation {
|
|
114
|
+
/**
|
|
115
|
+
* Tunnels that are detected by the extension. The remotePort is used for display purposes.
|
|
116
|
+
* The localAddress should be the complete local address (ex. localhost:1234) for connecting to the port. Tunnels provided through
|
|
117
|
+
* detected are read-only from the forwarded ports UI.
|
|
118
|
+
*/
|
|
119
|
+
environmentTunnels?: TunnelDescription[];
|
|
120
|
+
|
|
121
|
+
tunnelFeatures?: {
|
|
122
|
+
elevation: boolean;
|
|
123
|
+
/**
|
|
124
|
+
* One of the the options must have the ID "private".
|
|
125
|
+
*/
|
|
126
|
+
privacyOptions: TunnelPrivacy[];
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export interface TunnelCreationOptions {
|
|
131
|
+
/**
|
|
132
|
+
* True when the local operating system will require elevation to use the requested local port.
|
|
133
|
+
*/
|
|
134
|
+
elevationRequired?: boolean;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export enum CandidatePortSource {
|
|
138
|
+
None = 0,
|
|
139
|
+
Process = 1,
|
|
140
|
+
Output = 2
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
export type ResolverResult = (ResolvedAuthority | ManagedResolvedAuthority) & ResolvedOptions & TunnelInformation;
|
|
144
|
+
|
|
145
|
+
export class RemoteAuthorityResolverError extends Error {
|
|
146
|
+
static NotAvailable(message?: string, handled?: boolean): RemoteAuthorityResolverError;
|
|
147
|
+
static TemporarilyNotAvailable(message?: string): RemoteAuthorityResolverError;
|
|
148
|
+
|
|
149
|
+
constructor(message?: string);
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* An ExecServer allows spawning processes on a remote machine. An ExecServer is provided by resolvers. It can be
|
|
154
|
+
* acquired by `workspace.getRemoteExecServer` or from the context when in a resolver (`RemoteAuthorityResolverContext.execServer`).
|
|
155
|
+
*/
|
|
156
|
+
export interface ExecServer {
|
|
157
|
+
/**
|
|
158
|
+
* Spawns a given subprocess with the given command and arguments.
|
|
159
|
+
* @param command The command to execute.
|
|
160
|
+
* @param args The arguments to pass to the command.
|
|
161
|
+
* @param options Additional options for the spawned process.
|
|
162
|
+
* @returns A promise that gives access to the process' stdin, stdout and stderr streams, as well as the process' exit code.
|
|
163
|
+
*/
|
|
164
|
+
spawn(command: string, args: string[], options?: ExecServerSpawnOptions): Thenable<SpawnedCommand>;
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* Spawns an connector that allows to start a remote server. It is assumed the command starts a Code CLI. Additional
|
|
168
|
+
* arguments will be passed to the connector.
|
|
169
|
+
* @param command The command to execute. It is assumed the command spawns a Code CLI executable.
|
|
170
|
+
* @param args The arguments to pass to the connector
|
|
171
|
+
* @param options Additional options for the spawned process.
|
|
172
|
+
* @returns A promise that gives access to the spawned {@link RemoteServerConnector}. It also provides a stream to which standard
|
|
173
|
+
* log messages are written.
|
|
174
|
+
*/
|
|
175
|
+
spawnRemoteServerConnector?(command: string, args: string[], options?: ExecServerSpawnOptions): Thenable<RemoteServerConnector>;
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* Downloads the CLI executable of the desired platform and quality and pipes it to the
|
|
179
|
+
* provided process' stdin.
|
|
180
|
+
* @param buildTarget The CLI build target to download.
|
|
181
|
+
* @param command The command to execute. The downloaded bits will be piped to the command's stdin.
|
|
182
|
+
* @param args The arguments to pass to the command.
|
|
183
|
+
* @param options Additional options for the spawned process.
|
|
184
|
+
* @returns A promise that resolves when the process exits with a {@link ProcessExit} object.
|
|
185
|
+
*/
|
|
186
|
+
downloadCliExecutable?(buildTarget: CliBuild, command: string, args: string[], options?: ExecServerSpawnOptions): Thenable<ProcessExit>;
|
|
187
|
+
|
|
188
|
+
/**
|
|
189
|
+
* Gets the environment where the exec server is running.
|
|
190
|
+
* @returns A promise that resolves to an {@link ExecEnvironment} object.
|
|
191
|
+
*/
|
|
192
|
+
env(): Thenable<ExecEnvironment>;
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* Access to the file system of the remote.
|
|
196
|
+
*/
|
|
197
|
+
readonly fs: RemoteFileSystem;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
export type ProcessEnv = Record<string, string>;
|
|
201
|
+
|
|
202
|
+
export interface ExecServerSpawnOptions {
|
|
203
|
+
readonly env?: ProcessEnv;
|
|
204
|
+
readonly cwd?: string;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export interface SpawnedCommand {
|
|
208
|
+
readonly stdin: WriteStream;
|
|
209
|
+
readonly stdout: ReadStream;
|
|
210
|
+
readonly stderr: ReadStream;
|
|
211
|
+
readonly onExit: Thenable<ProcessExit>;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
export interface RemoteServerConnector {
|
|
215
|
+
readonly logs: ReadStream;
|
|
216
|
+
readonly onExit: Thenable<ProcessExit>;
|
|
217
|
+
/**
|
|
218
|
+
* Connect to a new code server, returning a stream that can be used to communicate with it.
|
|
219
|
+
* @param params The parameters for the code server.
|
|
220
|
+
* @returns A promise that resolves to a {@link ManagedMessagePassing} object that can be used with a resolver
|
|
221
|
+
*/
|
|
222
|
+
connect(params: ServeParams): Thenable<ManagedMessagePassing>;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
export interface ProcessExit {
|
|
226
|
+
readonly status: number;
|
|
227
|
+
readonly message?: string;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export interface ReadStream {
|
|
231
|
+
readonly onDidReceiveMessage: Event<Uint8Array>;
|
|
232
|
+
readonly onEnd: Thenable<void>;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
export interface WriteStream {
|
|
236
|
+
write(data: Uint8Array): void;
|
|
237
|
+
end(): void;
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
export interface ServeParams {
|
|
241
|
+
readonly socketId: number;
|
|
242
|
+
readonly commit?: string;
|
|
243
|
+
readonly quality: string;
|
|
244
|
+
readonly extensions: string[];
|
|
245
|
+
/** Whether server traffic should be compressed. */
|
|
246
|
+
readonly compress?: boolean;
|
|
247
|
+
/** Optional explicit connection token for the server. */
|
|
248
|
+
readonly connectionToken?: string;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
export interface CliBuild {
|
|
252
|
+
readonly quality: string;
|
|
253
|
+
/** 'LinuxAlpineX64' | 'LinuxX64' | 'LinuxARM64' | 'LinuxARM32' | 'DarwinX64' | 'DarwinARM64' | 'WindowsX64' | 'WindowsX86' | 'WindowsARM64' */
|
|
254
|
+
readonly buildTarget: string;
|
|
255
|
+
readonly commit: string;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
export interface ExecEnvironment {
|
|
259
|
+
readonly env: ProcessEnv;
|
|
260
|
+
/** 'darwin' | 'linux' | 'win32' */
|
|
261
|
+
readonly osPlatform: string;
|
|
262
|
+
/** uname.version or windows version number, undefined if it could not be read. */
|
|
263
|
+
readonly osRelease?: string;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
export interface RemoteFileSystem {
|
|
267
|
+
/**
|
|
268
|
+
* Retrieve metadata about a file.
|
|
269
|
+
*
|
|
270
|
+
* @param path The path of the file to retrieve metadata about.
|
|
271
|
+
* @returns The file metadata about the file.
|
|
272
|
+
* @throws an exception when `path` doesn't exist.
|
|
273
|
+
*/
|
|
274
|
+
stat(path: string): Thenable<FileStat>;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
export interface RemoteAuthorityResolver {
|
|
278
|
+
/**
|
|
279
|
+
* Resolve the authority part of the current opened `vscode-remote://` URI.
|
|
280
|
+
*
|
|
281
|
+
* This method will be invoked once during the startup of the editor and again each time
|
|
282
|
+
* the editor detects a disconnection.
|
|
283
|
+
*
|
|
284
|
+
* @param authority The authority part of the current opened `vscode-remote://` URI.
|
|
285
|
+
* @param context A context indicating if this is the first call or a subsequent call.
|
|
286
|
+
*/
|
|
287
|
+
resolve(authority: string, context: RemoteAuthorityResolverContext): ResolverResult | Thenable<ResolverResult>;
|
|
288
|
+
|
|
289
|
+
/**
|
|
290
|
+
* Resolves an exec server interface for the authority. Called if an
|
|
291
|
+
* authority is a midpoint in a transit to the desired remote.
|
|
292
|
+
*
|
|
293
|
+
* @param authority The authority part of the current opened `vscode-remote://` URI.
|
|
294
|
+
* @returns The exec server interface, as defined in a contract between extensions.
|
|
295
|
+
*/
|
|
296
|
+
resolveExecServer?(remoteAuthority: string, context: RemoteAuthorityResolverContext): ExecServer | Thenable<ExecServer>;
|
|
297
|
+
|
|
298
|
+
/**
|
|
299
|
+
* Get the canonical URI (if applicable) for a `vscode-remote://` URI.
|
|
300
|
+
*
|
|
301
|
+
* @returns The canonical URI or undefined if the uri is already canonical.
|
|
302
|
+
*/
|
|
303
|
+
getCanonicalURI?(uri: Uri): ProviderResult<Uri>;
|
|
304
|
+
|
|
305
|
+
/**
|
|
306
|
+
* Can be optionally implemented if the extension can forward ports better than the core.
|
|
307
|
+
* When not implemented, the core will use its default forwarding logic.
|
|
308
|
+
* When implemented, the core will use this to forward ports.
|
|
309
|
+
*
|
|
310
|
+
* To enable the "Change Local Port" action on forwarded ports, make sure to set the `localAddress` of
|
|
311
|
+
* the returned `Tunnel` to a `{ port: number, host: string; }` and not a string.
|
|
312
|
+
*/
|
|
313
|
+
tunnelFactory?: (tunnelOptions: TunnelOptions, tunnelCreationOptions: TunnelCreationOptions) => Thenable<Tunnel> | undefined;
|
|
314
|
+
|
|
315
|
+
/**p
|
|
316
|
+
* Provides filtering for candidate ports.
|
|
317
|
+
*/
|
|
318
|
+
showCandidatePort?: (host: string, port: number, detail: string) => Thenable<boolean>;
|
|
319
|
+
|
|
320
|
+
/**
|
|
321
|
+
* @deprecated Return tunnelFeatures as part of the resolver result in tunnelInformation.
|
|
322
|
+
*/
|
|
323
|
+
tunnelFeatures?: {
|
|
324
|
+
elevation: boolean;
|
|
325
|
+
public: boolean;
|
|
326
|
+
privacyOptions: TunnelPrivacy[];
|
|
327
|
+
};
|
|
328
|
+
|
|
329
|
+
candidatePortSource?: CandidatePortSource;
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
export interface ResourceLabelFormatter {
|
|
333
|
+
scheme: string;
|
|
334
|
+
authority?: string;
|
|
335
|
+
formatting: ResourceLabelFormatting;
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
export interface ResourceLabelFormatting {
|
|
339
|
+
label: string; // myLabel:/${path}
|
|
340
|
+
// For historic reasons we use an or string here. Once we finalize this API we should start using enums instead and adopt it in extensions.
|
|
341
|
+
// eslint-disable-next-line local/vscode-dts-literal-or-types, local/vscode-dts-string-type-literals
|
|
342
|
+
separator: '/' | '\\' | '';
|
|
343
|
+
tildify?: boolean;
|
|
344
|
+
normalizeDriveLetter?: boolean;
|
|
345
|
+
workspaceSuffix?: string;
|
|
346
|
+
workspaceTooltip?: string;
|
|
347
|
+
authorityPrefix?: string;
|
|
348
|
+
stripPathStartingSeparator?: boolean;
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
export namespace workspace {
|
|
352
|
+
export function registerRemoteAuthorityResolver(authorityPrefix: string, resolver: RemoteAuthorityResolver): Disposable;
|
|
353
|
+
export function registerResourceLabelFormatter(formatter: ResourceLabelFormatter): Disposable;
|
|
354
|
+
export function getRemoteExecServer(authority: string): Thenable<ExecServer | undefined>;
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
export namespace env {
|
|
358
|
+
|
|
359
|
+
/**
|
|
360
|
+
* The authority part of the current opened `vscode-remote://` URI.
|
|
361
|
+
* Defined by extensions, e.g. `ssh-remote+${host}` for remotes using a secure shell.
|
|
362
|
+
*
|
|
363
|
+
* *Note* that the value is `undefined` when there is no remote extension host but that the
|
|
364
|
+
* value is defined in all extension hosts (local and remote) in case a remote extension host
|
|
365
|
+
* exists. Use {@link Extension.extensionKind} to know if
|
|
366
|
+
* a specific extension runs remote or not.
|
|
367
|
+
*/
|
|
368
|
+
export const remoteAuthority: string | undefined;
|
|
369
|
+
|
|
370
|
+
}
|
|
371
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
// https://github.com/microsoft/vscode/issues/178713
|
|
7
|
+
|
|
8
|
+
declare module 'vscode' {
|
|
9
|
+
|
|
10
|
+
export namespace workspace {
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Saves the editor identified by the given resource and returns the resulting resource or `undefined`
|
|
14
|
+
* if save was not successful or no editor with the given resource was found.
|
|
15
|
+
*
|
|
16
|
+
* **Note** that an editor with the provided resource must be opened in order to be saved.
|
|
17
|
+
*
|
|
18
|
+
* @param uri the associated uri for the opened editor to save.
|
|
19
|
+
* @return A thenable that resolves when the save operation has finished.
|
|
20
|
+
*/
|
|
21
|
+
export function save(uri: Uri): Thenable<Uri | undefined>;
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Saves the editor identified by the given resource to a new file name as provided by the user and
|
|
25
|
+
* returns the resulting resource or `undefined` if save was not successful or cancelled or no editor
|
|
26
|
+
* with the given resource was found.
|
|
27
|
+
*
|
|
28
|
+
* **Note** that an editor with the provided resource must be opened in order to be saved as.
|
|
29
|
+
*
|
|
30
|
+
* @param uri the associated uri for the opened editor to save as.
|
|
31
|
+
* @return A thenable that resolves when the save-as operation has finished.
|
|
32
|
+
*/
|
|
33
|
+
export function saveAs(uri: Uri): Thenable<Uri | undefined>;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
declare module 'vscode' {
|
|
7
|
+
// https://github.com/microsoft/vscode/issues/133935
|
|
8
|
+
|
|
9
|
+
export interface SourceControlActionButton {
|
|
10
|
+
command: Command;
|
|
11
|
+
secondaryCommands?: Command[][];
|
|
12
|
+
description?: string;
|
|
13
|
+
enabled: boolean;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export interface SourceControl {
|
|
17
|
+
actionButton?: SourceControlActionButton;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
declare module 'vscode' {
|
|
7
|
+
// https://github.com/microsoft/vscode/issues/185269
|
|
8
|
+
|
|
9
|
+
export interface SourceControl {
|
|
10
|
+
historyProvider?: SourceControlHistoryProvider;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface SourceControlHistoryProvider {
|
|
14
|
+
actionButton?: SourceControlActionButton;
|
|
15
|
+
currentHistoryItemGroup?: SourceControlHistoryItemGroup;
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Fires when the action button changes
|
|
19
|
+
*/
|
|
20
|
+
onDidChangeActionButton: Event<void>;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Fires when the current history item group changes (ex: checkout)
|
|
24
|
+
*/
|
|
25
|
+
onDidChangeCurrentHistoryItemGroup: Event<void>;
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Fires when the history item groups change (ex: commit, push, fetch)
|
|
29
|
+
*/
|
|
30
|
+
// onDidChangeHistoryItemGroups: Event<SourceControlHistoryChangeEvent>;
|
|
31
|
+
|
|
32
|
+
provideHistoryItems(historyItemGroupId: string, options: SourceControlHistoryOptions, token: CancellationToken): ProviderResult<SourceControlHistoryItem[]>;
|
|
33
|
+
provideHistoryItemChanges(historyItemId: string, token: CancellationToken): ProviderResult<SourceControlHistoryItemChange[]>;
|
|
34
|
+
|
|
35
|
+
resolveHistoryItemGroupBase(historyItemGroupId: string, token: CancellationToken): ProviderResult<SourceControlHistoryItemGroup | undefined>;
|
|
36
|
+
resolveHistoryItemGroupCommonAncestor(historyItemGroupId1: string, historyItemGroupId: string, token: CancellationToken): ProviderResult<{ id: string; ahead: number; behind: number }>;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export interface SourceControlHistoryOptions {
|
|
40
|
+
readonly cursor?: string;
|
|
41
|
+
readonly limit?: number | { id?: string };
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export interface SourceControlHistoryItemGroup {
|
|
45
|
+
readonly id: string;
|
|
46
|
+
readonly label: string;
|
|
47
|
+
readonly upstream?: SourceControlRemoteHistoryItemGroup;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export interface SourceControlRemoteHistoryItemGroup {
|
|
51
|
+
readonly id: string;
|
|
52
|
+
readonly label: string;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export interface SourceControlHistoryItem {
|
|
56
|
+
readonly id: string;
|
|
57
|
+
readonly parentIds: string[];
|
|
58
|
+
readonly label: string;
|
|
59
|
+
readonly description?: string;
|
|
60
|
+
readonly icon?: Uri | { light: Uri; dark: Uri } | ThemeIcon;
|
|
61
|
+
readonly timestamp?: number;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export interface SourceControlHistoryItemChange {
|
|
65
|
+
readonly uri: Uri;
|
|
66
|
+
readonly originalUri: Uri | undefined;
|
|
67
|
+
readonly modifiedUri: Uri | undefined;
|
|
68
|
+
readonly renameUri: Uri | undefined;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// export interface SourceControlHistoryChangeEvent {
|
|
72
|
+
// readonly added: Iterable<SourceControlHistoryItemGroup>;
|
|
73
|
+
// readonly removed: Iterable<SourceControlHistoryItemGroup>;
|
|
74
|
+
// readonly modified: Iterable<SourceControlHistoryItemGroup>;
|
|
75
|
+
// }
|
|
76
|
+
|
|
77
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
declare module 'vscode' {
|
|
7
|
+
|
|
8
|
+
// todo@joaomoreno add issue reference
|
|
9
|
+
|
|
10
|
+
export interface SourceControl {
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Whether the source control is selected.
|
|
14
|
+
*/
|
|
15
|
+
readonly selected: boolean;
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* An event signaling when the selection state changes.
|
|
19
|
+
*/
|
|
20
|
+
readonly onDidChangeSelection: Event<boolean>;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
declare module 'vscode' {
|
|
7
|
+
// https://github.com/microsoft/vscode/issues/166615
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Represents the input box in the Source Control viewlet.
|
|
11
|
+
*/
|
|
12
|
+
export interface SourceControlInputBox {
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* The {@link TextDocument text} of the input box.
|
|
16
|
+
*/
|
|
17
|
+
readonly document: TextDocument;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
declare module 'vscode' {
|
|
7
|
+
|
|
8
|
+
// todo@joaomoreno add issue reference
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Represents the validation type of the Source Control input.
|
|
12
|
+
*/
|
|
13
|
+
export enum SourceControlInputBoxValidationType {
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Something not allowed by the rules of a language or other means.
|
|
17
|
+
*/
|
|
18
|
+
Error = 0,
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Something suspicious but allowed.
|
|
22
|
+
*/
|
|
23
|
+
Warning = 1,
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Something to inform about but not a problem.
|
|
27
|
+
*/
|
|
28
|
+
Information = 2
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export interface SourceControlInputBoxValidation {
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* The validation message to display.
|
|
35
|
+
*/
|
|
36
|
+
readonly message: string | MarkdownString;
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* The validation type.
|
|
40
|
+
*/
|
|
41
|
+
readonly type: SourceControlInputBoxValidationType;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Represents the input box in the Source Control viewlet.
|
|
46
|
+
*/
|
|
47
|
+
export interface SourceControlInputBox {
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Shows a transient contextual message on the input.
|
|
51
|
+
*/
|
|
52
|
+
showValidationMessage(message: string | MarkdownString, type: SourceControlInputBoxValidationType): void;
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* A validation function for the input box. It's possible to change
|
|
56
|
+
* the validation provider simply by setting this property to a different function.
|
|
57
|
+
*/
|
|
58
|
+
validateInput?(value: string, cursorPosition: number): ProviderResult<SourceControlInputBoxValidation>;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
// https://github.com/microsoft/vscode/issues/176316 @joyceerhl
|
|
7
|
+
|
|
8
|
+
declare module 'vscode' {
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Data about an item which can be shared.
|
|
12
|
+
*/
|
|
13
|
+
export interface ShareableItem {
|
|
14
|
+
/**
|
|
15
|
+
* A resource in the workspace that can be shared.
|
|
16
|
+
*/
|
|
17
|
+
resourceUri: Uri;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* If present, a selection within the `resourceUri`.
|
|
21
|
+
*/
|
|
22
|
+
selection?: Range;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* A provider which generates share links for resources in the editor.
|
|
27
|
+
*/
|
|
28
|
+
export interface ShareProvider {
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* A unique ID for the provider.
|
|
32
|
+
* This will be used to activate specific extensions contributing share providers if necessary.
|
|
33
|
+
*/
|
|
34
|
+
readonly id: string;
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* A label which will be used to present this provider's options in the UI.
|
|
38
|
+
*/
|
|
39
|
+
readonly label: string;
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* The order in which the provider should be listed in the UI when there are multiple providers.
|
|
43
|
+
*/
|
|
44
|
+
readonly priority: number;
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @param item Data about an item which can be shared.
|
|
49
|
+
* @param token A cancellation token.
|
|
50
|
+
* @returns A {@link Uri} representing an external link or sharing text. The provider result
|
|
51
|
+
* will be copied to the user's clipboard and presented in a confirmation dialog.
|
|
52
|
+
*/
|
|
53
|
+
provideShare(item: ShareableItem, token: CancellationToken): ProviderResult<Uri | string>;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export namespace window {
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Register a share provider. An extension may register multiple share providers.
|
|
60
|
+
* There may be multiple share providers for the same {@link ShareableItem}.
|
|
61
|
+
* @param selector A document selector to filter whether the provider should be shown for a {@link ShareableItem}.
|
|
62
|
+
* @param provider A share provider.
|
|
63
|
+
*/
|
|
64
|
+
export function registerShareProvider(selector: DocumentSelector, provider: ShareProvider): Disposable;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export interface TreeItem {
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* An optional property which, when set, inlines a `Share` option in the context menu for this tree item.
|
|
71
|
+
*/
|
|
72
|
+
shareableItem?: ShareableItem;
|
|
73
|
+
}
|
|
74
|
+
}
|