Ignore VS Code default exclusions
See original GitHub issueHey, I notice that createFileSystemWatcher
does not allow for inserting the list of default VS Code exclusions unlike for example findFiles
with its exclude
argument you can set to undefined
to make it use the default built-in excludes. That means currently this extension reports errors from even node_modules
and such and in my case that blows some of my projects up to thousands of errors. You might want to consider trying to somehow extract this exclusion list from VS Code and adjusting your glob (either statically or even better dynamically based on the exclusion list) to ignore these.
Issue Analytics
- State:
- Created 5 years ago
- Comments:32 (18 by maintainers)
Top Results From Across the Web
Choose folders to be ignored during search in VS Code
Temporary Exclusions. From the search function, click the ellipsis to show the files to include and files to exclude text boxes.
Read more >VS Code Tip of the Week: Exclude Git Ignore
This week's tip is the Exclude Git Ignore user setting. This is a great feature to declutter the tree explorer of VS Code...
Read more >User and Workspace Settings - Visual Studio Code
You can always reset a setting to the default value by hovering over a setting to ... VS Code will warn you and...
Read more >Hide or exclude folders and files from search in Visual Studio ...
To edit the file directly, use the shortcut CMD+Shift+P and search for Preferences: Open Keyboard Shortcuts (JSON) . In that file you can...
Read more >Exclude folders from search in VS Code - DeveloperF1.com
You can exclude files and complete folders from search in VS Code by simply listing unwanted entries in the files to exclude field....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
More FYI, @chrmarti kindly opened an issue for VS Code to look into this: https://github.com/Microsoft/vscode/issues/50874
What we’re seeing may not be entirely expected.
Looking at VS Code on my machine, I see the following behavior (always re-open the folder when testing).
Prevents linting *.md from vendor directory, but hides directory in explorer:
Does not exclude *.md from vendor directory:
Also does not exclude:
Which brings me back to suggesting
markdownlint.ignore
.Prevents linting *.md from vendor directory, no effect on explorer, no effect on
Ctrl+T
:Code-wise, I confirm that VS Code’s handling of
Ctrl+T
is to invokevscode.workspace.onDidOpenTextDocument
for every Markdown document it scans. There is no matching call tovscode.workspace.onDidCloseTextDocument
. Either or both may be a bug.I can’t yet see a way to tell the
Ctrl+T
scenario apart from the normal document open scenario from the extension’s code.markdownlint.ignore
seems to be the ideal solution for now.