Calva Commands#
This list is totally incomplete
If you want to help the Calva project, one way to do so is to help making this list of commands complete.
Calva's commands are part of the Calva API. They often accept arguments of some type, which you can use from keybindings and from Joyride (or another VS Code extension). Well behaved commands return a Promise, if it is async. You can utilize this with Joyride too, or with keybindings involving runCommands
.
Example shortcut bindings#
To illustrate how to provide arguments to the Calva commands, here's a keyboard shortcut binding for calva.refresh
:
{
"key": "ctrl+alt+c f1",
"command": "calva.refresh",
"args": {
"after": "component.repl/reset"
}
},
It sends along the :after
argument for the cider-nrepl/refresh
op. (The actual argument only makes sense with Component)
Here's another way to achieve something similar.
{
"key": "ctrl+alt+c f1",
"command": "runCommands",
"args": {
"commands": [
"calva.refresh",
{
"command": "calva.runCustomREPLCommand",
"args": "(component.repl/reset)"
}
]
}
}
REPL commands#
Commands that establishes or needs a REPL connection.
Command | Title | Arguments | Notes |
---|---|---|---|
calva.refresh |
Refreshes changed namespaces | A JSON object with stuff from cider-nrepl ops/refresh | Mostly meant for sending :dirs , :after , and :before . The print options may or may not work. |
calva.refreshAll |
Refreshes changed namespaces | A JSON object with stuff from cider-nrepl ops/refresh-aa | Mostly meant for sending :dirs , :after , and :before . The print options may or may not work. |
Wait, where are all the commands?#
Told you the list is incomplete... Please consider helping with making this a complete list! 🙏