4

I have a multi-root workspace set up, in which two out of the four folders are external thus I can't add specific settings to that folder. I would like to disable search on those folders, preferably in the workspace settings.

I couldn't find the right pattern to make that work :(

Below are my workspace settings, I am trying to filter files in the out folder:

"folders": [
    {
        "name": "Application"
        "path": "./application"
    },
    {
        "name": "Device"
        "path": "./device"
    },
    {
        "name": "Out"
        "path": "./out"
    }],
"settings": {
    // Configure glob patterns for excluding files and folders in searches. Inherits all glob patterns from the files.exclude setting.
    "search.exclude": {
        "out": true,
        "**/tests": true,
        ".tags": true
    },
Álvaro González
  • 142,137
  • 41
  • 261
  • 360
  • I'm facing the same problem right now. I'm using the remote workspace extension and search is not working because of my remote workdspace (ftp). I too would like to disable search on this particular workspace root so, the search can can work again. – EthraZa Jan 10 '19 at 16:14

1 Answers1

0

As proposed in https://stackoverflow.com/a/33418660/6225923, you can use the workspace settings and add patterns for folders to exclude, like this:

"search.excludeFolders": [
    "folder1",
    "folder2",
    "folder3",
    "path/to/other/folder4"
],

Additionally, make sure the search exlusion is still active is the settings.

Hildirim
  • 3
  • 1
  • Unfortunately that does not work. Below are my workspace settings: "folders": [ { "name": "Application" "path": "./application" }, { "name": "Device" "path": "./device" }, { "name": "Out" "path": "./out" }], "settings": { // Configure glob patterns for excluding files and folders in searches. Inherits all glob patterns from the files.exclude setting. "search.exclude": { "out": true, "**/tests": true, ".tags": true }, – user6668153 Jul 08 '18 at 07:15