mirror of
https://github.com/danog/code-server.git
synced 2024-11-27 04:45:52 +01:00
101c2a01f1
It seems reaching into lib/vscode for the types caused tsc to establish watches that caused it to restart over and over while vscode was building. The strategy used here is to symlink it instead which is the same thing we do for the proxy agent.
136 lines
2.8 KiB
TypeScript
136 lines
2.8 KiB
TypeScript
/**
|
|
* External interfaces for integration into code-server over IPC.
|
|
* This file exists in two locations:
|
|
* - typings/ipc.d.ts
|
|
* - lib/vscode/src/typings/ipc.d.ts
|
|
* The second is a symlink to the first.
|
|
*/
|
|
export interface Options {
|
|
base: string
|
|
disableTelemetry: boolean
|
|
disableUpdateCheck: boolean
|
|
}
|
|
|
|
export interface InitMessage {
|
|
type: "init"
|
|
id: string
|
|
options: VscodeOptions
|
|
}
|
|
|
|
export type Query = { [key: string]: string | string[] | undefined | Query | Query[] }
|
|
|
|
export interface SocketMessage {
|
|
type: "socket"
|
|
query: Query
|
|
permessageDeflate: boolean
|
|
}
|
|
|
|
export interface CliMessage {
|
|
type: "cli"
|
|
args: Args
|
|
}
|
|
|
|
export interface OpenCommandPipeArgs {
|
|
type: "open"
|
|
fileURIs?: string[]
|
|
folderURIs: string[]
|
|
forceNewWindow?: boolean
|
|
diffMode?: boolean
|
|
addMode?: boolean
|
|
gotoLineMode?: boolean
|
|
forceReuseWindow?: boolean
|
|
waitMarkerFilePath?: string
|
|
}
|
|
|
|
export type CodeServerMessage = InitMessage | SocketMessage | CliMessage
|
|
|
|
export interface ReadyMessage {
|
|
type: "ready"
|
|
}
|
|
|
|
export interface OptionsMessage {
|
|
id: string
|
|
type: "options"
|
|
options: WorkbenchOptions
|
|
}
|
|
|
|
export type VscodeMessage = ReadyMessage | OptionsMessage
|
|
|
|
export interface StartPath {
|
|
url: string
|
|
workspace: boolean
|
|
}
|
|
|
|
export interface Args {
|
|
"user-data-dir"?: string
|
|
|
|
"enable-proposed-api"?: string[]
|
|
"extensions-dir"?: string
|
|
"builtin-extensions-dir"?: string
|
|
"extra-extensions-dir"?: string[]
|
|
"extra-builtin-extensions-dir"?: string[]
|
|
"ignore-last-opened"?: boolean
|
|
|
|
locale?: string
|
|
|
|
log?: string
|
|
verbose?: boolean
|
|
|
|
_: string[]
|
|
}
|
|
|
|
export interface VscodeOptions {
|
|
readonly args: Args
|
|
readonly remoteAuthority: string
|
|
readonly startPath?: StartPath
|
|
}
|
|
|
|
export interface VscodeOptionsMessage extends VscodeOptions {
|
|
readonly id: string
|
|
}
|
|
|
|
export interface UriComponents {
|
|
readonly scheme: string
|
|
readonly authority: string
|
|
readonly path: string
|
|
readonly query: string
|
|
readonly fragment: string
|
|
}
|
|
|
|
export interface NLSConfiguration {
|
|
locale: string
|
|
availableLanguages: {
|
|
[key: string]: string
|
|
}
|
|
pseudo?: boolean
|
|
_languagePackSupport?: boolean
|
|
}
|
|
|
|
export interface WorkbenchOptions {
|
|
readonly workbenchWebConfiguration: {
|
|
readonly remoteAuthority?: string
|
|
readonly folderUri?: UriComponents
|
|
readonly workspaceUri?: UriComponents
|
|
readonly logLevel?: number
|
|
readonly workspaceProvider?: {
|
|
payload: [["userDataPath", string], ["enableProposedApi", string]]
|
|
}
|
|
}
|
|
readonly remoteUserDataUri: UriComponents
|
|
readonly productConfiguration: {
|
|
codeServerVersion?: string
|
|
readonly extensionsGallery?: {
|
|
readonly serviceUrl: string
|
|
readonly itemUrl: string
|
|
readonly controlUrl: string
|
|
readonly recommendationsUrl: string
|
|
}
|
|
}
|
|
readonly nlsConfiguration: NLSConfiguration
|
|
readonly commit: string
|
|
}
|
|
|
|
export interface WorkbenchOptionsMessage {
|
|
id: string
|
|
}
|