Skip to content

Commit

Permalink
fix: v0.44 cmd+shift+k to delete line
Browse files Browse the repository at this point in the history
  • Loading branch information
tjx666 committed Dec 18, 2024
1 parent c029a87 commit e2af05c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 15 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Key improvements:
- `⌘ + K`: Restored as VSCode's prefix shortcut (previously "Open Edit" in Cursor, now `⌘ + E`)
- `⌘ + L`: Restored as "Expand Line Selection" (previously "Open New Chat" in Cursor, now `⌘ + ]`)
- `⇧ + ⌘ + L`: Restored as "Select All Occurrences of Find Match" (previously "Insert Selection Into Chat" in Cursor, now `⌘ + ⇧ + ]`)
- `⇧ + ⌘ + K`: Restored as "Delete Line" (previously "[Add to Edit](https://docs.cursor.com/context/%40-symbols/%40-code#from-the-editor), just add current selection to composer", because open composer is `⌘ + I`, so, I change the command shortcut to `⇧ + ⌘ + I`)
- `⇧ + ⌘ + K`: Restored as "Delete Line" (previously "[Add to Edit](https://docs.cursor.com/context/%40-symbols/%40-code#from-the-editor), just add current selection to composer"). I didn't add a new shortcut for `Add to Edit`, custom it as you like.
- You can use `⇧ + ⌘ + K` to clear terminal in Cursor, because you can't make `⌘ + K` to clear terminal work in Cursor.

How to custom vscode keybinding?
Expand Down
12 changes: 4 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -1192,16 +1192,12 @@
{
"key": "shift+ctrl+k",
"mac": "shift+cmd+k",
"command": "-aipopup.action.modal.generate",
"when": "editorFocus && !composerBarIsVisible",
"args": {
"invocationType": "toggle"
}
"command": "-composer.openAsBar"
},
{
"key": "alt+shift+i",
"mac": "cmd+shift+i",
"command": "aipopup.action.modal.generate",
"key": "shift+ctrl+k",
"mac": "shift+cmd+k",
"command": "-aipopup.action.modal.generate",
"when": "editorFocus && !composerBarIsVisible",
"args": {
"invocationType": "toggle"
Expand Down
11 changes: 5 additions & 6 deletions src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,17 +67,16 @@ async function generateKeybindings(extensionPath: string) {
{
key: 'shift+ctrl+k',
mac: 'shift+cmd+k',
command: '-aipopup.action.modal.generate',
when: 'editorFocus && !composerBarIsVisible',
args: { invocationType: 'toggle' },
command: '-composer.openAsBar',
},
{
key: 'alt+shift+i',
mac: 'cmd+shift+i',
command: 'aipopup.action.modal.generate',
key: 'shift+ctrl+k',
mac: 'shift+cmd+k',
command: '-aipopup.action.modal.generate',
when: 'editorFocus && !composerBarIsVisible',
args: { invocationType: 'toggle' },
},

{
key: 'ctrl+l',
mac: 'cmd+l',
Expand Down

0 comments on commit e2af05c

Please sign in to comment.