vscode
vscode copied to clipboard
Add "Cycle Commands Group" to cycle commands with same keybind
The ability to cycle any series of commands with the same keyboard shortcut.
A Cycle Commands Group (CCG) should have:
- The ability to be named
- Unique keyboard shortcut and "when constraint" combination, same as regular keyboard shortcuts.
Example:
Use case for converting/manipulating text:
lowercase -----> UPPERCASE
^ |
| Ctrl+H |
| |
|-- camelCase <--|
Just a simple example where you have a given number of commands that you perhaps use frequently and does similar things (doesn't have to ofc.) and you may not want to have seperate commands for these. Just continue to use the same command until you reach your desired command.
Configuration could look like this:
{
"name": "Text Manipulation",
"keybind": "ctrl+h",
"when": "editorHasSelection",
"commands": [
text.tolowercase,
text.toUPPERCASE,
text.tocamelCase,
]
}