Skip to content

Richer files.exclude config options like 'hide' or 'grayOut' #19347

@borekb

Description

@borekb

Currently, files.exclude items can be set to true, false or an object like { "when": "$(basename).ts" }. When an item matches a pattern, it is hidden from the explorer.

I'd appreciate more control over how these things are displayed in the explorer. For example, this would be my files.exclude section:

"files.exclude": {
    // not interested in this at all
    "**/.git": "hide",
    "**/.DS_Store": "hide",

    // compiled JS files, I'd like to be able to browse them
    "dist": "grayOut",

    // new 'mode' field for the nested object
    "**/*.js": { "when": "$(basename).ts", "mode": "hide" }
}

For backwards compatibility, true would mean 'hide'.

Note that it would not change how items are e.g. excluded from search. It's purely about their appearance in the explorer.

Metadata

Metadata

Assignees

Labels

*out-of-scopePosted issue is not in scope of VS Codefeature-requestRequest for new features or functionalityfile-explorerExplorer widget issues

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions