Skip to content

[FEATURE]: add the ability to keybind a user's custom slash commands #47

@ariane-emory

Description

@ariane-emory

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

It would be useful if a user's custom slash commands (i.e., the Markdown files in their ~/.config/opencode/command directory could be bound to keystrokes.

This could be done by interpreting any key beginning with a / in the object under the "keybinds" key in the config file as the name of a custom command's Markdown file. For example, this JSON snippet:

{
  "keybinds": {
    "/my-command": "ctrl+shift+m"
  }
}

... would cause a ctrl+shift+m keystroke to replace the current contents of the prompt input text box with /my-command and immediately submit the prompt input text box's contents, triggering the user's /my-command command.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions