{% include “docs/development/editors/vscode/_common/_vscode_header.md” %}
VS Code watches external file changes, reloading the latest stored file if there is no conflicting working copy. Watching and detecting changes, however, can take a long time. The larger the code base, the longer VS Code takes to detect the file change. Excluding some directories from the search space improves the speed.
Note: You can manually configure file reloading with Modify in settings.json
.
To exclude a directory from VS Code’s watcher:
CMD/CTRL + comma
to open VS Code's settings.settings.json
Alternatively, you can directly modify settings.json
and add an exclude pattern. settings.json
contains all custom VS Code settings stored in a single JSON.
To manually exclude a directory from VS Code’s watcher:
Press CMD/CTRL + SHIFT + P
to open Command Palette.
Type settings
in the search field.
Click Preferences: Open Settings (JSON).
In settings.json
, add an exclude pattern similar to below and restart VS Code for changes to take effect.
"files.watcherExclude": { "**/.DS_Store": true, "**/.cipd": true, "**/.clang-format": true, "**/.clang-tidy": true, "**/.dir-locals.el": true, "**/.git": true, "**/.gitattributes": true, "**/.gitignore": true, "**/.hg": true, "**/.idea": true, "**/.jiri_manifest": true, "**/.jiri_root": true, "**/.ssh": true, "**/.style.yapf": true, "**/.svn": true, "**/AUTHORS": true, "**/CMakeLists.txt": true, "**/CODE_OF_CONDUCT.md": true, "**/CONTRIBUTING.md": true, "**/CVS": true, "**/LICENSE": true, "**/PATENTS": true, "**/buildtools": true, "**/examples": true, "**/prebuilt/test_data": true, "**/garnet/third_party": true, "**/out": true, "**/prebuilt": true, "**/rustfmt.toml": true, "**/src/chromium": true, "**/topaz": true, "**/zircon/experimental": true, "**/zircon/prebuilt": true, "**/zircon/third_party": true, }