Это ide на основе vs code(code oss), в ней будет встроенный умный апи роутинг, свой маркет с плагинами(агент харнесс, поддержка java/kotlin/мобильной разработки, командная разработка проектов, orca, оркестратор агентов
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/import*as vscode from'vscode';import{ getLocation, Location, parse }from'jsonc-parser';import{ provideInstalledExtensionProposals }from'./extensionsProposals';constOVERRIDE_IDENTIFIER_REGEX=/\[([^\[\]]*)\]/g;exportclassSettingsDocument{constructor(private document vscodeTextDocument
position vscodePosition _token vscodeCancellationToken vscodeCompletionItem vscodeCompletionList
location document documentposition
locationpath
location position
locationpath
location position
locationpath locationpath locationpath
location position
locationpath
location position
locationpath
location position
locationpath
ignoredExtensions
ignoredExtensions document
e
range location position
ignoredExtensions range
locationpath locationpathlength locationisAtPropertyKey
alreadyConfigured
alreadyConfigured Objectdocument
e
range location position
alreadyConfigured locationpreviousNode range
locationpath locationpathlength locationisAtPropertyKey
location position
location position
location Location position vscodePosition
node locationpreviousNode
node
nodeStart documentnodeoffset nodeEnd documentnodeoffset nodelength
nodeStartposition nodeEndposition
nodeStart nodeEnd
position position
location Location pos vscodePosition
locationisAtPropertyKey
previousNode locationpreviousNode
previousNode
offset documentpos
offset previousNodeoffset offset previousNodeoffset previousNodelength
location Location pos vscodePosition vscodeCompletionItem
completions vscodeCompletionItem
location pos
completions
range documentpos
range rangestartpos rangeendpos documentrange
range pos pos
variable
text variable
locationpreviousNode text text
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions
location Location pos vscodePosition vscodeCompletionItem
completions vscodeCompletionItem
location pos
completions
range documentpos
range rangestartpos rangeendpos documentrange
range pos pos
variable
text variable
locationpreviousNode text text
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions range vscodel10n
completions
location Location position vscodePosition vscodeCompletionItem
completions vscodeCompletionItem
locationpathlength
locationpath
range location position
completions
label vscodel10n
documentation vscodel10n
snippet locationisAtPropertyKey
range
completions
label vscodel10n
documentation vscodel10n
snippet locationisAtPropertyKey
range
location position
location position
completions
location Location position vscodePosition vscodeCompletionItem
completions vscodeCompletionItem
locationpathlength locationpathlength locationpath
range location position
completions
label vscodel10n
documentation vscodel10n
snippet locationpathlength
range
completions
label vscodel10n
documentation vscodel10n
snippet locationpathlength
range
completions
label vscodel10n
documentation vscodel10n
snippet locationpathlength
range
completions
label vscodel10n
documentation vscodel10n
snippet locationpathlength
range
completions
label vscodel10n
documentation vscodel10n
snippet locationpathlength
range
completions
label vscodel10n
documentation vscodel10n
snippet locationpathlength
range
locationpathlength location position
range location position
completions
label vscodel10n
documentation vscodel10n
snippet
range
completions
location Location position vscodePosition vscodeCompletionItem
locationpathlength location position
range location position
languages vscodelanguages
range vscodel10n
languagesl l range
range vscodeRange vscodeCompletionItem
languages vscodelanguages
completionItems
language languages
item language
itemkind vscodeCompletionItemKindProperty
itemrange range
completionItemsitem
completionItems
location Location position vscodePosition vscodeCompletionItem
locationpathlength locationisAtPropertyKey locationpreviousNode locationpreviousNodevalue locationpreviousNodevalue
startPosition documentlocationpreviousNodeoffset
endPosition startPosition locationpreviousNodevaluelength
donotSuggestLanguages
languageOverridesRanges vscodeRange
matches locationpreviousNodevalue
lastLanguageOverrideRange vscodeRange
matcheslength
lastLanguageOverrideRange documentlocationpreviousNodeoffset matchesindex documentlocationpreviousNodeoffset matchesindex matcheslength
languageOverridesRangeslastLanguageOverrideRange
lastLanguageOverrideRangeposition
donotSuggestLanguagesmatches
matches locationpreviousNodevalue
lastLanguageOverrideEndPosition lastLanguageOverrideRange lastLanguageOverrideRangeend startPosition
lastLanguageOverrideEndPositionendPosition
languageOverridesRanges lastLanguageOverrideEndPosition endPosition
languageOverrideRange languageOverridesRangesrange rangeposition
languageOverrideRange languageOverrideRangelanguageOverridesRanges
languages vscodelanguages
completionItems
language languages
donotSuggestLanguageslanguage
item
itemkind vscodeCompletionItemKindProperty
itemrange languageOverrideRange
completionItemsitem
completionItems
range vscodeRange vscodeCompletionItem
label
documentation
range
snippet
label
documentation
range
snippet
label
documentation
range
snippet
text range vscodeRange description insertText vscodeCompletionItem
item text
itemkind vscodeCompletionItemKindValue
itemdetail description
iteminsertText insertText insertText text
itemrange range
item
o label documentation snippet range vscodeRange vscodeCompletionItem
item olabel
itemkind vscodeCompletionItemKindValue
itemdocumentation odocumentation
iteminsertText osnippet
itemrange orange
item
"the path of the file relative to the workspace folder (e.g. myFolder/myFileFolder/myFile.txt)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeEditorLong'
)
,
,
.
.
t
(
"the full path of the file (e.g. /Users/Development/myFolder/myFileFolder/myFile.txt)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeFolderShort'
)
,
,
.
.
t
(
"the name of the folder the file is contained in (e.g. myFileFolder)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeFolderMedium'
)
,
,
.
.
t
(
"the path of the folder the file is contained in, relative to the workspace folder (e.g. myFolder/myFileFolder)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeFolderLong'
)
,
,
.
.
t
(
"the full path of the folder the file is contained in (e.g. /Users/Development/myFolder/myFileFolder)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'rootName'
)
,
,
.
.
t
(
"name of the workspace with optional remote name and workspace indicator if applicable (e.g. myFolder, myRemoteFolder [SSH] or myWorkspace (Workspace))"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'rootNameShort'
)
,
,
.
.
t
(
"shortened name of the workspace without suffixes (e.g. myFolder or myWorkspace)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'rootPath'
)
,
,
.
.
t
(
"file path of the workspace (e.g. /Users/Development/myWorkspace)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'folderName'
)
,
,
.
.
t
(
"name of the workspace folder the file is contained in (e.g. myFolder)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'folderPath'
)
,
,
.
.
t
(
"file path of the workspace folder the file is contained in (e.g. /Users/Development/myFolder)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'appName'
)
,
,
.
.
t
(
"e.g. VS Code"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'remoteName'
)
,
,
.
.
t
(
"e.g. SSH"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'dirty'
)
,
,
.
.
t
(
"an indicator for when the active editor has unsaved changes"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'separator'
)
,
,
.
.
t
(
"a conditional separator (' - ') that only shows when surrounded by variables with values"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeRepositoryName'
)
,
,
.
.
t
(
"the name of the active repository (e.g. vscode)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeRepositoryBranchName'
)
,
,
.
.
t
(
"the name of the active branch in the active repository (e.g. main)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'activeEditorState'
)
,
,
.
.
t
(
"the state of the active editor (e.g. modified)."
)
)
)
;
return
;
}
private
async
provideEditorLabelCompletionItems
(
:
,
:
.
)
:
Promise
<
.
[
]
>
{
const
:
.
[
]
=
[
]
;
if
(
!
this
.
isCompletingPropertyValue
(
,
)
)
{
return
;
}
let
=
this
.
.
getWordRangeAtPosition
(
,
/\$\{[^"\}]*\}?/
)
;
if
(
!
||
.
.
isEqual
(
)
||
.
.
isEqual
(
)
&&
this
.
.
getText
(
)
.
endsWith
(
'}'
)
)
{
=
new
vscode
.
Range
(
,
)
;
}
const
getText
=
(
:
string
)
=>
{
const
=
'${'
+
+
'}'
;
return
.
?
:
JSON
.
stringify
(
)
;
}
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'dirname'
)
,
,
.
.
t
(
"The parent folder name of the editor (e.g. myFileFolder)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'dirname(1)'
)
,
,
.
.
t
(
"The nth parent folder name of the editor"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'filename'
)
,
,
.
.
t
(
"The file name of the editor without its directory or extension (e.g. myFile)"
)
)
)
;
.
push
(
this
.
newSimpleCompletionItem
(
getText
(
'extname'
)
,
,
.
.
t
(
"The file extension of the editor (e.g. txt)"
)
)
)
;
return
;
}
private
async
provideFilesAssociationsCompletionItems
(
:
,
:
.
)
:
Promise
<
.
[
]
>
{
const
:
.
[
]
=
[
]
;
if
(
.
.
===
2
)
{
// Key
if
(
.
[
1
]
===
''
)
{
const
=
this
.
getReplaceRange
(
,
)
;
.
push
(
this
.
newSnippetCompletionItem
(
{
:
.
.
t
(
"Files with Extension"
)
,
:
.
.
t
(
"Map all files matching the glob pattern in their filename to the language with the given identifier."
)
,
:
.
?
'"*.${1:extension}": "${2:language}"'
:
'{ "*.${1:extension}": "${2:language}" }'
,
}
)
)
;
.
push
(
this
.
newSnippetCompletionItem
(
{
:
.
.
t
(
"Files with Path"
)
,
:
.
.
t
(
"Map all files matching the absolute path glob pattern in their path to the language with the given identifier."
)
,
:
.
?
'"/${1:path to file}/*.${2:extension}": "${3:language}"'
:
'{ "/${1:path to file}/*.${2:extension}": "${3:language}" }'
/* Suggest the configured language if the position is in the match range */
if
(
!
.
contains
(
)
)
{
.
push
(
[
1
]
.
trim
(
)
)
;
}
=
OVERRIDE_IDENTIFIER_REGEX
.
exec
(
.
.
)
;
}
const
=
?
.
:
;
if
(
.
isBefore
(
)
)
{
.
push
(
new
vscode
.
Range
(
,
)
)
;
}
const
=
.
find
(
=>
.
contains
(
)
)
;
/**
* Skip if suggestions are for first language override range
* Since VSCode registers language overrides to the schema, JSON language server does suggestions for first language override.
*/