Repository navigation
Expand file tree
/
Copy pathDefault.sublime-keymap
More file actions
95 lines (92 loc) · 3.72 KB
/
Copy pathDefault.sublime-keymap
File metadata and controls
95 lines (92 loc) · 3.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
// CodeContinue - Key Bindings
//
// DEFAULT KEYBINDINGS: Not enabled by default to prevent conflicts with other packages.
// You configure your preferred shortcuts once in your User keymap.
//
// NOTE: By default, suggestions are NOT automatically triggered on Enter.
// You trigger suggestions on-demand via shortcut (or Command Palette).
//
// HOW TO SET UP (SPLIT VIEW):
// 1. Go to: Preferences > Package Settings > CodeContinue > Key Bindings
// (or press Ctrl+Shift+P >> "Preferences: CodeContinue Key Bindings")
// 2. COPY your preferred configuration from the LEFT pane (this file).
// 3. PASTE it into the RIGHT pane (User keymap) inside the [ ... ] list.
// 4. SAVE the User keymap file (Ctrl+S / Cmd+S).
//
// -----------------------------------------------------------------------------
// RECOMMENDED CONFIGURATIONS (Copy to the right pane):
// -----------------------------------------------------------------------------
//
// === Option 1: Ctrl+Enter to Suggest, Tab to Accept (Recommended) ===
// [
// // 1. Trigger code suggestion on-demand:
// {
// "keys": ["ctrl+enter"],
// "command": "code_continue_suggest"
// },
// // 2. Accept suggestion (only active when a suggestion is visible):
// {
// "keys": ["tab"],
// "command": "code_continue_accept",
// "context": [
// { "key": "code_continue_visible", "operator": "equal", "operand": true }
// ]
// },
// // 3. Dismiss suggestion:
// {
// "keys": ["escape"],
// "command": "code_continue_dismiss",
// "context": [
// { "key": "code_continue_visible", "operator": "equal", "operand": true }
// ]
// }
// ]
//
// === Option 2: Single Key (Ctrl+Enter for BOTH Suggest AND Accept) ===
// When a suggestion is visible, Ctrl+Enter accepts it.
// When no suggestion is visible, Ctrl+Enter triggers a new suggestion.
// [
// {
// "keys": ["ctrl+enter"],
// "command": "code_continue_accept",
// "context": [
// { "key": "code_continue_visible", "operator": "equal", "operand": true }
// ]
// },
// {
// "keys": ["ctrl+enter"],
// "command": "code_continue_suggest"
// }
// ]
//
// === Option 3: Alt+/ to Suggest, Tab to Accept ===
// [
// {
// "keys": ["alt+/"],
// "command": "code_continue_suggest"
// },
// {
// "keys": ["tab"],
// "command": "code_continue_accept",
// "context": [
// { "key": "code_continue_visible", "operator": "equal", "operand": true }
// ]
// }
// ]
//
// -----------------------------------------------------------------------------
// INDIVIDUAL COMMANDS REFERENCE:
// -----------------------------------------------------------------------------
//
// • Trigger Suggestion:
// { "keys": ["ctrl+enter"], "command": "code_continue_suggest" }
//
// • Accept Suggestion (with context check so key only activates when visible):
// { "keys": ["tab"], "command": "code_continue_accept", "context": [{ "key": "code_continue_visible", "operator": "equal", "operand": true }] }
// { "keys": ["ctrl+enter"], "command": "code_continue_accept", "context": [{ "key": "code_continue_visible", "operator": "equal", "operand": true }] }
// { "keys": ["right"], "command": "code_continue_accept", "context": [{ "key": "code_continue_visible", "operator": "equal", "operand": true }] }
// { "keys": ["end"], "command": "code_continue_accept", "context": [{ "key": "code_continue_visible", "operator": "equal", "operand": true }] }
//
// • Dismiss Suggestion:
// { "keys": ["escape"], "command": "code_continue_dismiss", "context": [{ "key": "code_continue_visible", "operator": "equal", "operand": true }] }
[]