-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpackage.json
235 lines (235 loc) · 8.42 KB
/
package.json
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
{
"name": "vscode-clangd-extra-config",
"displayName": "clangd: Extra config",
"description": "Add more clangd options, what passed to command line",
"author": "SR_team",
"publisher": "sr-team",
"license": "MIT",
"version": "0.0.2",
"repository": {
"type": "git",
"url": "https://github.com/sr-tream/vscode-clangd-extra-config.git"
},
"engines": {
"vscode": "^1.65.0"
},
"categories": [
"Programming Languages"
],
"keywords": [
"C",
"C++",
"clang",
"clangd"
],
"activationEvents": [
"onStartupFinished"
],
"main": "./out/extension.js",
"contributes": {
"configuration": [
{
"title": "clangd: Extra config",
"properties": {
"clangd.extraConfig.RestartServerOnChange": {
"type": "boolean",
"default": false,
"markdownDescription": "Automatically restart `clangd` server, when extra configs changed",
"order": 0
}
}
},
{
"title": "clangd feature options",
"properties": {
"clangd.extraConfig.features.allScopesCompletion": {
"type": "boolean",
"default": true,
"description": "If set to true, code completion will include index symbols that are not defined in the scopes (e.g. namespaces) visible from the code completion point. Such completions can insert scope qualifiers"
},
"clangd.extraConfig.features.backgroundIndex": {
"type": "string",
"default": "low",
"enum": [
"disabled",
"background",
"low",
"normal"
],
"enumDescriptions": [
"Disable background indexing.",
"Minimum priority, runs on idle CPUs. May leave 'performance' cores unused.",
"Reduced priority compared to interactive work.",
"Same priority as other clangd work."
],
"description": "Index project code in the background and persist index on disk."
},
"clangd.extraConfig.features.clangTidy": {
"type": "boolean",
"default": true,
"description": "Enable clang-tidy diagnostics"
},
"clangd.extraConfig.features.completionParse": {
"type": "string",
"default": "auto",
"enum": [
"auto",
"always",
"never"
],
"enumDescriptions": [
"Use text-based completion if the parser is not ready",
"Block until the parser can be used",
"Always used text-based completion"
],
"description": "Whether the clang-parser is used for code-completion"
},
"clangd.extraConfig.features.completionStyle": {
"type": "string",
"default": "detailed",
"enum": [
"detailed",
"bundled"
],
"enumDescriptions": [
"One completion item for each semantically distinct completion, with full type information",
"Similar completion items (e.g. function overloads) are combined. Type information shown where possible"
],
"description": "Granularity of code completion suggestions"
},
"clangd.extraConfig.features.debugOrigin": {
"type": "boolean",
"default": false,
"description": "Show origins of completion items"
},
"clangd.extraConfig.features.fallbackStyle": {
"type": "string",
"default": "LLVM",
"description": "clang-format style to apply by default when no .clang-format file is found"
},
"clangd.extraConfig.features.functionArgPlaceholders": {
"type": "boolean",
"default": true,
"description": "When disabled, completions contain only parentheses for function calls. When enabled, completions also contain placeholders for method parameters"
},
"clangd.extraConfig.features.headerInsertion": {
"type": "string",
"default": "iwyu",
"enum": [
"iwyu",
"never"
],
"enumDescriptions": [
"Include what you use. Insert the owning header for top-level symbols, unless the header is already directly included or the symbol is forward-declared",
"Never insert #include directives as part of code completion"
],
"description": "Add #include directives when accepting code completions"
},
"clangd.extraConfig.features.headerInsertionDecorators": {
"type": "boolean",
"default": true,
"description": "Prepend a circular dot or space before the completion label, depending on whether an include line will be inserted or not"
},
"clangd.extraConfig.features.importInsertions": {
"type": "boolean",
"default": false,
"description": "If header insertion is enabled, add #import directives when accepting code completions or fixing includes in Objective-C code"
},
"clangd.extraConfig.features.includeIneligibleResults": {
"type": "boolean",
"default": false,
"description": "Include ineligible completion results (e.g. private members)"
},
"clangd.extraConfig.features.limitReferences": {
"type": "integer",
"default": 1000,
"description": "Limit the number of references returned by clangd. 0 means no limit"
},
"clangd.extraConfig.features.limitResults": {
"type": "integer",
"default": 100,
"description": "Limit the number of results returned by clangd. 0 means no limit"
},
"clangd.extraConfig.features.rerankingModel": {
"type": "string",
"default": "decision_forest",
"enum": [
"heuristics",
"decision_forest"
],
"enumDescriptions": [
"Use heuristics to rank code completion items",
"Use Decision Forest model to rank completion items"
],
"description": "Model to use to rank code-completion items"
},
"clangd.extraConfig.features.renameFileLimits": {
"type": "integer",
"default": 50,
"description": "Limit the number of files to be affected by symbol renaming. 0 means no limit"
}
}
},
{
"title": "clangd miscellaneous options",
"properties": {
"clangd.extraConfig.miscellaneous.workerThreads": {
"type": "integer",
"default": -1,
"markdownDescription": "Number of async workers used by clangd. Background index also uses this many workers.\n\n`-1` or less to autodetect cores count.\n\n`0` to handle client requests on main thread. Background index still uses its own thread."
},
"clangd.extraConfig.miscellaneous.mallocTrim": {
"type": "boolean",
"default": true,
"description": "Release memory periodically via malloc_trim(3)."
},
"clangd.extraConfig.miscellaneous.parseForwardingFunctions": {
"type": "boolean",
"default": false,
"description": "Parse all emplace-like functions in included headers"
},
"clangd.extraConfig.miscellaneous.pchStorage": {
"type": "string",
"default": "disk",
"enum": [
"disk",
"memory"
],
"enumDescriptions": [
"store PCHs on disk",
"store PCHs in memory"
],
"description": "Storing PCHs in memory increases memory usages, but may improve performance"
},
"clangd.extraConfig.miscellaneous.useDirtyHeaders": {
"type": "boolean",
"default": false,
"description": "Use files open in the editor when parsing headers instead of reading from the disk"
}
}
}
]
},
"scripts": {
"vscode:prepublish": "npm run compile",
"compile": "tsc -p ./",
"watch": "tsc -watch -p ./",
"pretest": "npm run compile && npm run lint",
"lint": "eslint src --ext ts",
"test": "vscode-test"
},
"devDependencies": {
"@types/vscode": "^1.65.0",
"@types/mocha": "^10.0.7",
"@types/node": "20.x",
"@typescript-eslint/eslint-plugin": "^7.14.1",
"@typescript-eslint/parser": "^7.11.0",
"eslint": "^8.57.0",
"typescript": "^5.4.5",
"@vscode/test-cli": "^0.0.9",
"@vscode/test-electron": "^2.4.0"
},
"extensionDependencies": [
"llvm-vs-code-extensions.vscode-clangd"
]
}