blob: d780f7b06d4ae0f118acce4e2b68ffa58fe25ad7 [file] [log] [blame] [view]
ljustene262c8412017-04-12 08:29:041# Visual Studio Code Dev
2
3Visual Studio Code is a free, lightweight and powerful code editor for Windows,
4Mac and Linux, based on Electron/Chromium. It has built-in support for
5JavaScript, TypeScript and Node.js and a rich extension ecosystem that adds
6intellisense, debugging, syntax highlighting etc. for many languages (C++,
Michael Thiessenf643e29f2020-03-24 20:23:017Python, Go, Java). It works without too much setup. Get started
ljustene262c8412017-04-12 08:29:048[here](https://code.visualstudio.com/docs).
9
10It is NOT a full-fledged IDE like Visual Studio. The two are completely
11separate products. The only commonality with Visual Studio is that both are
12from Microsoft.
13
14Here's what works well:
15
16* Editing code works well especially when you get used to the [keyboard
17 shortcuts](https://code.visualstudio.com/docs/customization/keybindings).
18 VS Code is very responsive and can handle even big code bases like Chromium.
19* Git integration is a blast. Built-in side-by-side view, local commit and
20 even extensions for
21 [history](https://marketplace.visualstudio.com/items?itemName=donjayamanne.githistory)
22 and
23 [blame view](https://marketplace.visualstudio.com/items?itemName=ryu1kn.annotator).
24* [Debugging](https://code.visualstudio.com/Docs/editor/debugging) works
25 well, even though startup times can be fairly high (~40 seconds with
26 gdb on Linux, much lower on Windows). You can step through code, inspect
27 variables, view call stacks for multiple threads etc.
Ryan Heise9a711432020-10-14 23:55:3928 * For more information on debugging Python code, see [here](vscode_python.md).
ljustene262c8412017-04-12 08:29:0429* Opening files and searching solution-wide works well now after having
30 problems in earlier versions.
31* Building works well. Build tools are easy to integrate. Warnings and errors
32 are displayed on a separate page and you can click to jump to the
33 corresponding line of code.
Daniel Murphyd9e88fbb2020-03-17 19:26:2334* VSCode Remote, which allows you to edit remotely-hosted code, and even run
35 computationally expensive plugins like vscode-clangd on the remote
36 server/workstation (see the [Remote section](#Remote)). Great for working-
James Cook3a41598b2020-03-25 18:47:3837 from-home. (Googlers: See [go/vscode-remote](http://go/vscode-remote)].)
chaopengba312ce2017-02-12 03:38:2538
chaopengca285112017-03-02 15:39:0439[TOC]
40
ljustene262c8412017-04-12 08:29:0441## Updating This Page
chaopengba312ce2017-02-12 03:38:2542
ljustene262c8412017-04-12 08:29:0443Please keep this doc up-to-date. VS Code is still in active development and
44subject to changes. This doc is checked into the Chromium git repo, so if you
45make changes, read the [documentation
Johann48fbca92021-07-16 18:29:4146guidelines](documentation_guidelines.md)
47and [submit a change list](contributing.md).
chaopengba312ce2017-02-12 03:38:2548
ljustene262c8412017-04-12 08:29:0449All file paths and commands have been tested on Linux. Windows and Mac might
50require a slightly different setup (e.g. `Ctrl` -> `Cmd`). Please update this
51page accordingly.
chaopengba312ce2017-02-12 03:38:2552
ljustene262c8412017-04-12 08:29:0453## Setup
chaopengba312ce2017-02-12 03:38:2554
ljustene262c8412017-04-12 08:29:0455### Installation
chaopengba312ce2017-02-12 03:38:2556
ljustene262c8412017-04-12 08:29:0457Follow the steps on https://code.visualstudio.com/docs/setup/setup-overview. To
Bartek Nowierskifa835f8c2021-02-24 00:36:0258run it on Linux, just navigate to Chromium's `src` folder and type `code .` in a
ljustene262c8412017-04-12 08:29:0459terminal. The argument to `code` is the base directory of the workspace. VS
60Code does not require project or solution files. However, it does store
61workspace settings in a `.vscode` folder in your base directory.
chaopengba312ce2017-02-12 03:38:2562
Mounir Lamouri1679feab2019-01-25 19:30:0363### Fixes for Known Issues
64
65#### Git on Windows
Mounir Lamouri8202f362019-01-14 11:48:2666
67If you only have the `depot_tools` Git installed on your machine, even though it
68is in your PATH, VS Code will ignore it as it seems to be looking for `git.exe`.
69You will have to add the following to your settings in order for the Git
70integration to work:
71
Mounir Lamouri1679feab2019-01-25 19:30:0372```json
Mounir Lamouri8202f362019-01-14 11:48:2673{
74 "git.path": "C:\\src\\depot_tools\\git.bat"
75}
76```
77
ljustene262c8412017-04-12 08:29:0478### Useful Extensions
chaopengba312ce2017-02-12 03:38:2579
ljustene262c8412017-04-12 08:29:0480Up to now, you have a basic version of VS Code without much language support.
81Next, we will install some useful extensions. Jump to the extensions window
82(`Ctrl+Shift+X`) and install these extensions, you will most likely use them
83every day:
chaopengba312ce2017-02-12 03:38:2584
ljustene262c8412017-04-12 08:29:0485* ***C/C++*** -
Jesse McKennafffd8112020-05-08 19:18:4886 Code formatting, debugging, Intellisense. Enables the use of clang-format
87 (via the `C_Cpp.clang_format_path` setting) and format-on-save (via the
88 `editor.formatOnSave` setting).
ljustene262c8412017-04-12 08:29:0489* ***Python*** -
90 Linting, intellisense, code formatting, refactoring, debugging, snippets.
James Cook9f7c73d2017-06-20 15:06:1991* ***Toggle Header/Source*** -
92 Toggles between .cc and .h with `F4`. The C/C++ extension supports this as
93 well through `Alt+O` but sometimes chooses the wrong file when there are
94 multiple files in the workspace that have the same name.
ljustene262c8412017-04-12 08:29:0495* ***Protobuf support*** -
96 Syntax highlighting for .proto files.
Kenichi Ishibashib6d2e3b2020-04-22 18:16:0797* [***Mojom IDL support***](https://github.com/GoogleChromeLabs/mojom-language-support) -
98 Syntax highlighting and a
99 [language server](https://microsoft.github.io/language-server-protocol/)
Kenichi Ishibashi93c7b8e2021-11-05 05:42:23100 for .mojom files.
Jesse McKennafffd8112020-05-08 19:18:48101* ***vscode-clangd*** -
102 If you do not plan to use VSCode for debugging, vscode-clangd is a great
103 alternative to C/C++ IntelliSense. It knows about how to compile Chromium,
104 enabling it to provide smarter autocomplete than C/C++ IntelliSense as well
105 as allowing you to jump from functions to their definitions. See
106 [clangd.md](clangd.md) for setup instructions.
Tal Pressmanbcb58ae92020-06-02 23:36:10107 If you need to debug, enable C/C++ extension but set "C_Cpp: Intelli Sense Engine" to disabled,
108 and restart VSCode.
ljustene262c8412017-04-12 08:29:04109* ***Rewrap*** -
110 Wrap lines at 80 characters with `Alt+Q`.
Daniel Murphyd9e88fbb2020-03-17 19:26:23111* ***Remote*** -
112 Remotely connect to your workstation through SSH using your laptop. See the
113 [Remote](#Remote) section for more information about how to set this up.
chaopengba312ce2017-02-12 03:38:25114
ljustene262c8412017-04-12 08:29:04115The following extensions might be useful for you as well:
chaopengba312ce2017-02-12 03:38:25116
ljustene262c8412017-04-12 08:29:04117* ***Annotator*** -
118 Git blame view.
119* ***Git History (git log)*** -
120 Git history view.
121* ***chromium-codesearch*** -
Jesse McKennafffd8112020-05-08 19:18:48122 Mac and Linux only: adds ability to open the current line in [Chromium Code
123 Search](https://cs.chromium.org/). All other functionality is deprecated, so
124 currently only of limited usefulness.
ljustene262c8412017-04-12 08:29:04125* ***change-case*** -
126 Quickly change the case of the current selection or current word.
127* ***Instant Markdown*** -
128 Instant markdown (.md) preview in your browser as you type. This document
129 was written with this extension!
chaopengba312ce2017-02-12 03:38:25130
ljustene262c8412017-04-12 08:29:04131Also be sure to take a look at the
Jesse McKennafffd8112020-05-08 19:18:48132[VS Code marketplace](https://marketplace.visualstudio.com/VSCode) to check out
133other useful extensions.
chaopengba312ce2017-02-12 03:38:25134
ljustene262c8412017-04-12 08:29:04135### Color Scheme
136Press `Ctrl+Shift+P, color, Enter` to pick a color scheme for the editor. There
137are also tons of [color schemes available for download on the
138marketplace](https://marketplace.visualstudio.com/search?target=VSCode&category=Themes&sortBy=Downloads).
chaopengba312ce2017-02-12 03:38:25139
ljustene262c8412017-04-12 08:29:04140### Usage Tips
141* `Ctrl+P` opens a search box to find and open a file.
142* `F1` or `Ctrl+Shift+P` opens a search box to find a command (e.g. Tasks: Run
143 Task).
144* `Ctrl+K, Ctrl+S` opens the key bindings editor.
145* ``Ctrl+` `` toggles the built-in terminal.
146* `Ctrl+Shift+M` toggles the problems view (linter warnings, compile errors
Quinten Yearsley317532d2021-10-20 17:10:31147 and warnings). You'll switch a lot between terminal and problem view during
ljustene262c8412017-04-12 08:29:04148 compilation.
149* `Alt+O` switches between the source/header file.
150* `Ctrl+G` jumps to a line.
151* `F12` jumps to the definition of the symbol at the cursor (also available on
152 right-click context menu).
153* `Shift+F12` or `F1, CodeSearchReferences, Return` shows all references of
154 the symbol at the cursor.
155* `F1, CodeSearchOpen, Return` opens the current file in Code Search.
156* `Ctrl+D` selects the word at the cursor. Pressing it multiple times
157 multi-selects the next occurrences, so typing in one types in all of them,
158 and `Ctrl+U` deselects the last occurrence.
159* `Ctrl+K, Z` enters Zen Mode, a fullscreen editing mode with nothing but the
160 current editor visible.
161* `Ctrl+X` without anything selected cuts the current line. `Ctrl+V` pastes
162 the line.
163
Michael Thiessenf643e29f2020-03-24 20:23:01164### Java/Android Support
Victor Hugo Vianna Silvac37c9b72021-10-28 00:32:32165
166*Before anything*, add these to your settings.json.
167```
168// LightWeight is the language support, the feature we care about. The other
169// modes include build functionality with Maven and Gradle. They try to build
170// on their own and end up showing thousands of errors.
171"java.server.launchMode": "LightWeight",
172// Avoids overwriting the custom .classpath file (c.f. next section).
173"java.configuration.updateBuildConfiguration": "disabled",
174```
175Then install the "Language Support for Java" extension. If you installed it
176before setting the configs above, uninstall, delete the <project> folder (c.f.
177next section) and reinstall. You also don't need any of the remaining extensions
178in "Extension Pack for Java".
Michael Thiessenf643e29f2020-03-24 20:23:01179
180#### Setting up code completion/reference finding/etc.
Mehran Mahmoudib96ca412020-03-25 21:48:14181You'll need to generate a placeholder .classpath file and locate it. In order
182to generate it, right click on any Java source folder in the left panel and
183choose "Add folder to java source path". Its location will depend on whether
184you're doing local or remote development. Local path on linux will look
185something like:
Michael Thiessenf643e29f2020-03-24 20:23:01186
187`~/.vscode/data/User/workspaceStorage/<hash>/redhat.java/jdt_ws/<project>/.classpath`
188
Mehran Mahmoudib96ca412020-03-25 21:48:14189You might find multiple folders when looking for `<project>`. Choose anything except
190`jdt.ls-java-project`. If you only see `jdt.ls-java-project`, try using the
191"Add folder to java source path" option again.
192
Michael Thiessenf643e29f2020-03-24 20:23:01193If doing remote development, the file will be under `~/.vscode-server/` on your
194remote machine.
195
Michael Thiessene057a6c2020-03-25 19:24:01196You'll need to replace all of the contents of that file with the contents of
197`tools/android/eclipse/.classpath` (external) or
198`clank/development/ide/eclipse/.classpath` (generated by gclient runhooks for
199Chrome developers), and then replace some paths as vscode interprets some paths
200differently from eclipse.
Michael Thiessenf643e29f2020-03-24 20:23:01201* Replace: `kind="src" path="` with `kind="src" path="_/`
Michael Thiessene057a6c2020-03-25 19:24:01202 * eg. `<classpathentry kind="src" path="_/android_webview/glue/java/src"/>`
Michael Thiessenf643e29f2020-03-24 20:23:01203* Replace: `kind="lib" path="../src` with `kind="lib" path="_`
Michael Thiessene057a6c2020-03-25 19:24:01204 * eg.
205`<classpathentry kind="lib" path="_/out/Debug/lib.java/base/base_java.jar"/>`
Michael Thiessenf643e29f2020-03-24 20:23:01206* Remove all nested paths (or exclude them from their parents). At time of
207writing:
208 * `third_party/android_protobuf/src/java/src/main/java`
209 * `third_party/junit/src/src/main/java`
210
Henry Jiandabdddf2020-03-26 17:59:39211Also, make sure
212`export ANDROID_HOME=/usr/local/google/home/{your_ldap}/Android/Sdk` is in the
213remote machine's `~/.bashrc`.
214
Michael Thiessenf643e29f2020-03-24 20:23:01215Then restart vscode, open a Java file, and wait for a bit.
216
Michael Thiessene057a6c2020-03-25 19:24:01217Debugging tips:
218* Right clicking on a folder in vscode and clicking "Add folder to java source
219path" will error if there are syntax problems with your classpath. (Don't use
220this actually add new paths to your classpath as it won't work correctly)
221 * If there are no syntax errors, ensure the correct .classpath file is being
222 used by seeing if the folder was actually added to the .classpath file you
223 edited.
224
ljustene262c8412017-04-12 08:29:04225## Setup For Chromium
226
227VS Code is configured via JSON files. This paragraph contains JSON configuration
228files that are useful for Chromium development, in particular. See [VS Code
229documentation](https://code.visualstudio.com/docs/customization/overview) for an
230introduction to VS Code customization.
231
232### Workspace Settings
Darwin Huang985c38a2018-11-21 19:24:13233Open the file [//tools/vscode/settings.json5](/tools/vscode/settings.json5),
234and check out the default settings there. Feel free to commit added or removed
235settings to enable better team development, or change settings locally to suit
236personal preference. Remember to replace `<full_path_to_your_home>`! To use
237these settings wholesale, enter the following commands into your terminal while
238at the src directory:
ljustene262c8412017-04-12 08:29:04239```
Darwin Huang985c38a2018-11-21 19:24:13240$ mkdir .vscode/
241$ cp tools/vscode/settings.json5 .vscode/settings.json
ljustene262c8412017-04-12 08:29:04242```
243
Jesse McKennafffd8112020-05-08 19:18:48244Note: these settings assume that the workspace folder (the root folder displayed
Bartek Nowierskifa835f8c2021-02-24 00:36:02245in the Explorer tab) is Chromium's `src/` directory. If this is not the case,
246replace any references to ${workspaceFolder} with the path to your `src/`.
Jesse McKennafffd8112020-05-08 19:18:48247
ljustene262c8412017-04-12 08:29:04248### Tasks
Dan Harringtonb426cf9b2020-09-10 19:47:08249Next, we'll tell VS Code how to compile our code, run tests, and to read
250warnings and errors from the build output. Open the file
251[//tools/vscode/tasks.json5](/tools/vscode/tasks.json5). This will provide tasks
252to do basic things. You might have to adjust the commands to your situation and
253needs. To use these settings wholesale, enter the following command into your
254terminal:
ljustene262c8412017-04-12 08:29:04255```
Darwin Huang985c38a2018-11-21 19:24:13256$ cp tools/vscode/tasks.json5 .vscode/tasks.json
ljustene262c8412017-04-12 08:29:04257```
258
259### Launch Commands
260Launch commands are the equivalent of `F5` in Visual Studio: They launch some
261program or a debugger. Optionally, they can run some task defined in
262`tasks.json`. Launch commands can be run from the debug view (`Ctrl+Shift+D`).
Darwin Huang985c38a2018-11-21 19:24:13263Open the file at [//tools/vscode/launch.json5](/tools/vscode/launch.json5) and
Jesse McKenna37eceb82020-06-02 00:03:50264adjust the example launch commands to your situation and needs (e.g., the value
265of "type" needs adjustment for Windows). To use these settings wholesale, enter
266the following command into your terminal:
ljustene262c8412017-04-12 08:29:04267```
Darwin Huang985c38a2018-11-21 19:24:13268$ cp tools/vscode/launch.json5 .vscode/launch.json
ljustene262c8412017-04-12 08:29:04269```
270
271### Key Bindings
272To edit key bindings, press `Ctrl+K, Ctrl+S`. You'll see the defaults on the
273left and your overrides on the right stored in the file `keybindings.json`. To
274change a key binding, copy the corresponding key binding to the right. It's
275fairly self-explanatory.
276
277You can bind any command to a key, even commands specified by extensions like
278`CodeSearchOpen`. For instance, to bind `CodeSearchOpen` to `F2` to , simply add
279`{ "key": "F2", "command": "cs.open" },`.
280Note that the command title `CodeSearchOpen` won't work. You have to get the
281actual command name from the [package.json
282file](https://github.com/chaopeng/vscode-chromium-codesearch/blob/master/package.json)
283of the extension.
284
285If you are used to other editors, you can also install your favorite keymap.
286For instance, to install eclipse keymaps, install the
287`vscode-eclipse-keybindings` extension. More keymaps can be found
288[in the marketplace](https://marketplace.visualstudio.com/search?target=vscode&category=Keymaps).
289
Darwin Huang985c38a2018-11-21 19:24:13290Some key bindings that are likely to be useful for you are available at
291[//tools/vscode/keybindings.json5](/tools/vscode/keybindings.json5). Please
292take a look and adjust them to your situation and needs. To use these settings
293wholesale, enter the following command into your terminal:
ljustene262c8412017-04-12 08:29:04294```
Darwin Huang985c38a2018-11-21 19:24:13295$ cp tools/vscode/keybindings.json5 .vscode/keybindings.json
ljustene262c8412017-04-12 08:29:04296```
297
Daniel Murphyd9e88fbb2020-03-17 19:26:23298### Remote
299VSCode now has a
300[Remote](https://code.visualstudio.com/docs/remote/remote-overview) framework
301that allows you to use VSCode on your laptop while your code is hosted
302elsewhere. This really shines when used in conjunction with the vscode-clangd plugin,
303which allows clangd to run remotely as well.
304
305To get this to run, install the Remote pack extension, and then make sure your
306ssh config file has your remote connection:
307
308`~/.ssh/config`:
309```
310Host my-connection
311 HostName my-remote-host.corp.company.com
312```
313
314VSCode will then list this connection in the 'Remote Explorer' section on the
315left. To launch VSCode with this connection, click on the '+window' icon next
316to the listed hostname. It has you choose a folder - use the 'src' folder root.
317This will open a new VSCode window in 'Remote' mode. ***Now you can install
318extensions specifically for your remote connection, like vscode-clangd, etc.***
319
Peter Wen3ba91202020-06-17 15:56:54320#### Chromebooks
321
322For Googlers, [here](http://go/vscode/remote_development_via_web) are
323Google-specific instructions for setting up remote development on chromebooks
324without using Crostini.
325
Daniel Murphyd9e88fbb2020-03-17 19:26:23326#### Windows & SSH
Yuwei Huang1c4f50c2021-08-06 22:41:56327
328VSCode remote tools requires 'sshd' which isn't installed on Windows by default.
329
330For Googlers, sshd should already be installed on your workstation, and VSCode
331should work remotely if you followed the setup instructions at
332[go/building-chrome-win](http://go/building-chrome-win). If you are still having
333problems, please refer to
334[go/vscode-remote#windows](http://go/vscode-remote#windows).
335
336Non-Googlers may follow may follow Microsoft's instructions for
337[installing the OpenSSH server](https://docs.microsoft.com/en-us/windows-server/administration/openssh/openssh_install_firstuse).
338VSCode should work remotely after following this step.
Daniel Murphyd9e88fbb2020-03-17 19:26:23339
Dan Harringtonb06ce2f2019-04-09 15:35:29340### Snippets
341There are some useful snippets provided in
342[//tools/vscode/cpp.json5](/tools/vscode/cpp.json5).
343
Mounir Lamouri3b9e31d2019-07-30 20:14:41344You can either install them in your user profile (path may vary depending on the
345platform):
346```
347$ cp tools/vscode/cpp.json5 ~/.config/Code/User/snippets/cpp.json
348```
349
350Or install them as project snippets after installing the [Project
351Snippets](https://marketplace.visualstudio.com/items?itemName=rebornix.project-snippets)
352extension:
353```
354$ cp tools/vscode/cpp.json5 .vscode/snippets/cpp.json
355```
356
ljustene262c8412017-04-12 08:29:04357### Tips
358
359#### The `out` folder
360Automatically generated code is put into a subfolder of out/, which means that
361these files are ignored by VS Code (see files.exclude above) and cannot be
Christian Dullweberd67c9b32018-04-03 08:30:42362opened e.g. from quick-open (`Ctrl+P`).
363As of version 1.21, VS Code does not support negated glob commands, but you can
364define a set of exclude pattern to include only out/Debug/gen:
Christian Dullweberbabb96e12018-05-28 14:00:14365```
Christian Dullweberd67c9b32018-04-03 08:30:42366"files.exclude": {
367 // Ignore build output folders. Except out/Debug/gen/
368 "out/[^D]*/": true,
369 "out/Debug/[^g]*": true,
370 "out/Debug/g[^e]*": true,
371 "out_*/**": true,
372},
Christian Dullweberbabb96e12018-05-28 14:00:14373```
Christian Dullweberd67c9b32018-04-03 08:30:42374
375Once it does, you can use
ljustene262c8412017-04-12 08:29:04376```
377"!out/Debug/gen/**": true
378```
379in files.exclude instead of the symlink.
380
381#### Using VS Code as git editor
382Add `[core] editor = "code --wait"` to your `~/.gitconfig` file in order to use
383VS Code as editor for git commit messages etc. Note that the editor starts up
384significantly slower than nano or vim. To use VS Code as merge tool, add
385`[merge] tool = code`.
386
387#### Task Names
388Note that we named the tasks `1-build_chrome_debug`, `2-build_chrome_release`
389etc. This allows you to quickly execute tasks by pressing their number:
390Press `Ctrl+P` and enter `task <n>`, where `<n>` is the number of the task. You
391can also create a keyboard shortcut for running a task. `File > Preferences >
392Keyboard Shortcuts` and add `{ "key": "ctrl+r", "command":
393"workbench.action.tasks.runTask", "when": "!inDebugMode" }`. Then it's
394sufficient to press `Ctrl+R` and enter `<n>`.
395
396#### Working on Laptop
Bartek Nowierskifa835f8c2021-02-24 00:36:02397You might want to disable git status autorefresh to save battery.
chaopengca285112017-03-02 15:39:04398
399```
chaopeng5c66dfe2017-03-22 13:51:45400"git.autorefresh": false,
chaopengca285112017-03-02 15:39:04401```
402
Tommy Nyquistdc2ceaa42021-03-15 20:29:04403#### Editing in multiple Git repositories
404If you frequently work in multiple Git repositories that are part of the Chromium repository, you might find that the built-in tooling does not work as expected for files that exist below folders that are part of a `.gitignore` file checked in to Chromium.
405
406To work around this, you can add the directories you edit as separate `folders` entries in your workspace configuration, and ensure that the directories that are ignored in Chromium are listed **before** the Chromium `src` path.
407
408To edit this, go to `Settings` -> Select the `Workspace` tab, and choose to open as JSON (button in the top right), and configure `folders` like this (change paths to match your local setup and usage):
409
410```
411{
412 "folders": [
413 {
414 "path": "chromium/src/third_party/perfetto"
415 },
416 {
417 "path": "chromium/src"
418 }
419 ]
420}
421```
422
Jianpeng Chaob4048b82018-08-28 23:40:01423### Unable to open $File resource is not available when debugging Chromium on Linux
424Chromium [recently changed](https://docs.google.com/document/d/1OX4jY_bOCeNK7PNjVRuBQE9s6BQKS8XRNWGK8FEyh-E/edit?usp=sharing)
425the file path to be relative to the output dir. Check
426`gn args out/$dir --list` if `strip_absolute_paths_from_debug_symbols` is true (which is the default),
427set `cwd` to the output dir. otherwise, set `cwd` to `${workspaceRoot}`.
428
Bartek Nowierskifa835f8c2021-02-24 00:36:02429### You-Complete-Me
430The You-Complete-Me VS Code extension is now
431[deprecated](https://github.com/richard1122/vscode-youcompleteme#deprecated)
432with a suggestion to use clangd.
Jesse McKennafffd8112020-05-08 19:18:48433
chaopengba312ce2017-02-12 03:38:25434### More
ljustene262c8412017-04-12 08:29:04435More tips and tricks can be found
sangwoo.ko5fe74c732017-09-01 14:44:56436[here](https://github.com/Microsoft/vscode-tips-and-tricks/blob/master/README.md).