Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio Code files.exclude setting not working

Tags:

I am using Unity and trying to exclude .meta files from the file explorer sidebar. I navigated to File->Preferences->User Settings (or Workspace settings, doesn't matter), and set the contents of the file to the following:

// Place your settings in this file to overwrite default and user settings. {         "files.exclude": {         "**/.meta": true     } } 

...and saved my changes. Yet, when I click the Refresh icon or close/reopen my folder view, I am still seeing all the .meta files showing up in the left pane. Am I doing something wrong here?

like image 788
vargonian Avatar asked Nov 19 '15 18:11

vargonian


People also ask

How exclude files from VS Code search?

Persistent Exclusions From menu choose File ➡️ Preferences ➡️ Settings ➡️ User/Workspace Settings and filter default settings to search . You can modify the search. exclude setting (copy from default setting to your user or workspace settings). That will apply only to searches.

How do I show excluded files in Visual Studio?

In Visual Studio, right-click on the file to be excluded from build, choose Properties, Configuration Properties -> General -> Excluded From Build -> Yes -> OK.


1 Answers

My problem was basing my pattern off of the existing ones, which excluded specific file names rather than patterns. I simply needed to add an asterisk before the file extension, i.e.

"**/*.meta" 

instead of

"**/.meta" 
like image 75
vargonian Avatar answered Oct 02 '22 04:10

vargonian