Skip to content

Removing a contributes.keybindings rule by keybindings.json #114536

@kasecato

Description

@kasecato

I want to remove the contributes.keybindings by keybindings.json.

The use case is to load settings from an external file into the key mapping extension and overwrite the default package.json's contributes.keybindings setting with keybindings.json.

package.json

    "contributes": {
        "keybindings": [
            {
                "key": "shift+f6",
                "mac": "shift+f6",
                "command": "editor.action.rename",
                "when": "editorHasRenameProvider && editorTextFocus && !editorReadonly"
            },

keybindings.json (Not working: macOS, Version: 1.52.1)

[
            {
                "key": "-shift+f6",
                "mac": "-shift+f6",
                "command": "editor.action.rename",
                "when": "editorHasRenameProvider && editorTextFocus && !editorReadonly"
            },
]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions