1- // Place your key bindings in this file to overwrite the defaults
21[
3- // Vim navigate backwards/forwards
2+ /**
3+ * ----------------------------------------------------------------------------
4+ * General keybindings
5+ * ----------------------------------------------------------------------------
6+ */
7+ // Attempt to open workspace settings.json
48 {
5- "key" : " ctrl+o" ,
6- "command" : " workbench.action.navigateBack" ,
7- "when" : " editorTextFocus"
9+ "key" : " cmd-," ,
10+ "command" : " workbench.action.openSettingsJson"
811 },
912 {
10- "key" : " ctrl+i" ,
11- "command" : " workbench.action.navigateForward" ,
12- "when" : " editorTextFocus"
13+ "key" : " cmd-k cmd-," ,
14+ "command" : " macros.openWorkspaceSettingsJSON"
1315 },
14- {
15- "key" : " cmd+k p" ,
16- "command" : " extension.copyRelativePathOfActiveFile" ,
17- "when" : " editorTextFocus"
18- },
19- {
20- "key" : " cmd+k f" ,
21- "command" : " workbench.action.files.copyPathOfActiveFile" ,
22- "when" : " editorTextFocus"
23- },
24- {
25- "key" : " cmd-k l" ,
26- "command" : " latex-workshop.tab" ,
27- "when" : " editorTextFocus"
28- },
29- {
30- "key" : " cmd-alt-m" ,
31- "command" : " workbench.action.terminal.focus"
32- },
33- {
34- "key" : " cmd-alt-m" ,
35- "command" : " workbench.action.terminal.focus"
36- },
37- {
38- "key" : " cmd-shift-b" ,
39- "command" : " editor.action.revealDefinition" ,
40- "when" : " editorHasDefinitionProvider && editorTextFocus && !isInEmbeddedEditor"
41- },
42- // terrible defaults for "rails run specs"
43- {
44- "key" : " shift+cmd+t" ,
45- "command" : " workbench.action.reopenClosedEditor"
46- },
47- {
48- "key" : " cmd+k cmd+f" ,
49- "command" : " extension.runFileSpecs" ,
50- "when" : " editorTextFocus"
51- },
52- // Open keybindings.json file, since there's no default shortcut for it (LOL)
16+ // Open keyboard shortcuts
5317 {
5418 "key" : " cmd+k cmd+k" ,
5519 "command" : " workbench.action.openGlobalKeybindingsFile"
5923 "key" : " cmd+k cmd+n" ,
6024 "command" : " macros.clearOutputAndNotifications"
6125 },
62- // Rerun last apex test class
63- {
64- "key" : " cmd+k cmd+x" ,
65- "command" : " macros.runLastApexTestClass"
66- },
67- // Rerun last apex test
68- {
69- "key" : " cmd+k cmd+t" ,
70- "command" : " macros.runLastApexTestMethod"
71- },
7226 // Jump between change history
7327 {
7428 "key" : " cmd+]" ,
11367 {
11468 "key" : " cmd+8" ,
11569 "command" : " workbench.action.openEditorAtIndex8"
70+ },
71+ /**
72+ * ----------------------------------------------------------------------------
73+ * Vim Helpers
74+ * ----------------------------------------------------------------------------
75+ */
76+ // Vim navigate backwards/forwards
77+ {
78+ "key" : " ctrl+o" ,
79+ "command" : " workbench.action.navigateBack" ,
80+ "when" : " editorTextFocus"
81+ },
82+ {
83+ "key" : " ctrl+i" ,
84+ "command" : " workbench.action.navigateForward" ,
85+ "when" : " editorTextFocus"
86+ },
87+ /**
88+ * ----------------------------------------------------------------------------
89+ * File Helpers
90+ * ----------------------------------------------------------------------------
91+ */
92+ {
93+ "key" : " cmd+k p" ,
94+ "command" : " extension.copyRelativePathOfActiveFile" ,
95+ "when" : " editorTextFocus"
96+ },
97+ {
98+ "key" : " cmd+k f" ,
99+ "command" : " workbench.action.files.copyPathOfActiveFile" ,
100+ "when" : " editorTextFocus"
101+ },
102+ /**
103+ * ----------------------------------------------------------------------------
104+ * Terminal Helpers
105+ * ----------------------------------------------------------------------------
106+ */
107+ {
108+ "key" : " cmd-alt-m" ,
109+ "command" : " workbench.action.terminal.focus"
110+ },
111+ {
112+ "key" : " cmd-alt-m" ,
113+ "command" : " workbench.action.terminal.focus"
114+ },
115+ {
116+ "key" : " cmd-shift-b" ,
117+ "command" : " editor.action.revealDefinition" ,
118+ "when" : " editorHasDefinitionProvider && editorTextFocus && !isInEmbeddedEditor"
119+ },
120+ /**
121+ * ----------------------------------------------------------------------------
122+ * Rspec Helpers
123+ * ----------------------------------------------------------------------------
124+ */
125+ // terrible defaults for "rails run specs"
126+ {
127+ "key" : " shift+cmd+t" ,
128+ "command" : " workbench.action.reopenClosedEditor"
129+ },
130+ {
131+ "key" : " cmd+k cmd+f" ,
132+ "command" : " extension.runFileSpecs" ,
133+ "when" : " editorTextFocus"
134+ },
135+ /**
136+ * ----------------------------------------------------------------------------
137+ * Apex Helpers
138+ * ----------------------------------------------------------------------------
139+ */
140+ // Rerun last apex test class
141+ {
142+ "key" : " cmd+k cmd+x" ,
143+ "command" : " macros.runLastApexTestClass"
144+ },
145+ // Rerun last apex test
146+ {
147+ "key" : " cmd+k cmd+t" ,
148+ "command" : " macros.runLastApexTestMethod"
149+ },
150+ /**
151+ * ----------------------------------------------------------------------------
152+ * What is this?
153+ * ----------------------------------------------------------------------------
154+ */
155+ {
156+ "key" : " cmd-k l" ,
157+ "command" : " latex-workshop.tab" ,
158+ "when" : " editorTextFocus"
116159 }
117160]
0 commit comments