Skip to content

Make it easier to bind keyoard shortcuts to custom REPL commands #1173

Closed
@PEZ

Description

When creating a custom REPL command it is a bit of a roundabout way to bind a shortcut to it. If Calva predefined some easy to remember shortcuts to easy to remember custom command keys, it would be a matter of assigning one of those keys to a custom command definition to use it as a shortcut.

The current command for bringing down the custom commands menu is ctrl+alt+space. We could change that to be ctrl+alt+space space and then pre-bind ctrl+alt+space <whatever> to custom commands with key <whatever>.

<whatever> could be things like 0-9, a-z, enter, tab, right/left/up/down, and some more single character things found on most keyboards.

Example. With this custom snippet definition:

    "calva.customREPLCommandSnippets": [
        {
            "name": "Remount CLJS App",
            "key": "r",
            "repl": "cljs",
            "ns": "example.app",
            "snippet": "(start)"
        }
    ]

Typing ctrl+alt+space r would call this snippet.

Metadata

Assignees

No one assigned

    Labels

    repluxUser experience related

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions