You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- **PR Description**
This adds a new `0` keybinding to the side panels that focuses whatever
main view is currently displayed, with the goal of making it easier to
scroll the main view (using the normal navigation keys `,` `.` `<` `>`),
and being able to search the main view using `/`.
Alternatively to pressing `0` you can also click the main view to focus
it. Note that previously it was possible to go directly to the staging
panel by clicking in the main view when a file was selected; this now
takes a double click, because the first click just focuses the main
view, but you can go to staging from there by clicking again.
I'm reasonably happy with the overall behavior, but it takes some
getting used to, so we'll want to test this for a while to see if it
doesn't make the focus handling too confusing.
Fixes#3988.
Copy file name to clipboardExpand all lines: docs/keybindings/Keybindings_en.md
+20
Original file line number
Diff line number
Diff line change
@@ -68,6 +68,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
68
68
|`` ` ``| Toggle file tree view | Toggle file view between flat and tree layout. Flat layout shows all file paths in a single list, tree layout groups files by directory. |
69
69
|`` - ``| Collapse all files | Collapse all directories in the files tree |
70
70
|`` = ``| Expand all files | Expand all directories in the file tree |
71
+
|`` 0 ``| Focus main view ||
71
72
|`` / ``| Search the current view by text ||
72
73
73
74
## Commit summary
@@ -112,6 +113,7 @@ If you would instead like to start an interactive rebase from the selected commi
112
113
|`` C ``| Copy (cherry-pick) | Mark commit as copied. Then, within the local commits view, you can press `V` to paste (cherry-pick) the copied commit(s) into your checked out branch. At any time you can press `<esc>` to cancel the selection. |
113
114
|`` <c-t> ``| Open external diff tool (git difftool) ||
114
115
|`` * ``| Select commits of current branch ||
116
+
|`` 0 ``| Focus main view ||
115
117
|`` <enter> ``| View files ||
116
118
|`` w ``| View worktree options ||
117
119
|`` / ``| Search the current view by text ||
@@ -153,6 +155,7 @@ If you would instead like to start an interactive rebase from the selected commi
153
155
|`` f ``| Fetch | Fetch changes from remote. |
154
156
|`` - ``| Collapse all files | Collapse all directories in the files tree |
155
157
|`` = ``| Expand all files | Expand all directories in the file tree |
158
+
|`` 0 ``| Focus main view ||
156
159
|`` / ``| Search the current view by text ||
157
160
158
161
## Local branches
@@ -178,6 +181,7 @@ If you would instead like to start an interactive rebase from the selected commi
178
181
|`` R ``| Rename branch ||
179
182
|`` u ``| View upstream options | View options relating to the branch's upstream e.g. setting/unsetting the upstream and resetting to the upstream. |
180
183
|`` <c-t> ``| Open external diff tool (git difftool) ||
184
+
|`` 0 ``| Focus main view ||
181
185
|`` <enter> ``| View commits ||
182
186
|`` w ``| View worktree options ||
183
187
|`` / ``| Filter the current view by text ||
@@ -204,6 +208,9 @@ If you would instead like to start an interactive rebase from the selected commi
204
208
|-----|--------|-------------|
205
209
|`` mouse wheel down (fn+up) ``| Scroll down ||
206
210
|`` mouse wheel up (fn+down) ``| Scroll up ||
211
+
|`` <tab> ``| Switch view | Switch to other view (staged/unstaged changes). |
212
+
|`` <esc> ``| Exit back to side panel ||
213
+
|`` / ``| Search the current view by text ||
207
214
208
215
## Main panel (patch building)
209
216
@@ -264,6 +271,7 @@ If you would instead like to start an interactive rebase from the selected commi
|`` <c-t> ``| Open external diff tool (git difftool) ||
266
273
|`` * ``| Select commits of current branch ||
274
+
|`` 0 ``| Focus main view ||
267
275
|`` <enter> ``| View commits ||
268
276
|`` w ``| View worktree options ||
269
277
|`` / ``| Filter the current view by text ||
@@ -282,6 +290,7 @@ If you would instead like to start an interactive rebase from the selected commi
282
290
|`` s ``| Sort order ||
283
291
|`` g ``| Reset | View reset options (soft/mixed/hard) for resetting onto selected item. |
284
292
|`` <c-t> ``| Open external diff tool (git difftool) ||
293
+
|`` 0 ``| Focus main view ||
285
294
|`` <enter> ``| View commits ||
286
295
|`` w ``| View worktree options ||
287
296
|`` / ``| Filter the current view by text ||
@@ -297,6 +306,14 @@ If you would instead like to start an interactive rebase from the selected commi
297
306
|`` f ``| Fetch | Fetch updates from the remote repository. This retrieves new commits and branches without merging them into your local branches. |
298
307
|`` / ``| Filter the current view by text ||
299
308
309
+
## Secondary
310
+
311
+
| Key | Action | Info |
312
+
|-----|--------|-------------|
313
+
|`` <tab> ``| Switch view | Switch to other view (staged/unstaged changes). |
314
+
|`` <esc> ``| Exit back to side panel ||
315
+
|`` / ``| Search the current view by text ||
316
+
300
317
## Stash
301
318
302
319
| Key | Action | Info |
@@ -306,6 +323,7 @@ If you would instead like to start an interactive rebase from the selected commi
306
323
|`` d ``| Drop | Remove the stash entry from the stash list. |
307
324
|`` n ``| New branch | Create a new branch from the selected stash entry. This works by git checking out the commit that the stash entry was created from, creating a new branch from that commit, then applying the stash entry to the new branch as an additional commit. |
308
325
|`` r ``| Rename stash ||
326
+
|`` 0 ``| Focus main view ||
309
327
|`` <enter> ``| View files ||
310
328
|`` w ``| View worktree options ||
311
329
|`` / ``| Filter the current view by text ||
@@ -334,6 +352,7 @@ If you would instead like to start an interactive rebase from the selected commi
Copy file name to clipboardExpand all lines: docs/keybindings/Keybindings_ja.md
+20
Original file line number
Diff line number
Diff line change
@@ -51,6 +51,14 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
51
51
|`` ] ``| 次のタブ ||
52
52
|`` [ ``| 前のタブ ||
53
53
54
+
## Secondary
55
+
56
+
| Key | Action | Info |
57
+
|-----|--------|-------------|
58
+
|`` <tab> ``| パネルを切り替え | Switch to other view (staged/unstaged changes). |
59
+
|`` <esc> ``| Exit back to side panel ||
60
+
|`` / ``| 検索を開始 ||
61
+
54
62
## Stash
55
63
56
64
| Key | Action | Info |
@@ -60,6 +68,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
60
68
|`` d ``| Drop | Remove the stash entry from the stash list. |
61
69
|`` n ``| 新しいブランチを作成 | Create a new branch from the selected stash entry. This works by git checking out the commit that the stash entry was created from, creating a new branch from that commit, then applying the stash entry to the new branch as an additional commit. |
62
70
|`` r ``| Stashを変更 ||
71
+
|`` 0 ``| Focus main view ||
63
72
|`` <enter> ``| View files ||
64
73
|`` w ``| View worktree options ||
65
74
|`` / ``| Filter the current view by text ||
@@ -78,6 +87,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
|`` <c-t> ``| Open external diff tool (git difftool) ||
80
89
|`` * ``| Select commits of current branch ||
90
+
|`` 0 ``| Focus main view ||
81
91
|`` <enter> ``| View files ||
82
92
|`` w ``| View worktree options ||
83
93
|`` / ``| 検索を開始 ||
@@ -127,6 +137,7 @@ If you would instead like to start an interactive rebase from the selected commi
127
137
|`` C ``| コミットをコピー (cherry-pick) | Mark commit as copied. Then, within the local commits view, you can press `V` to paste (cherry-pick) the copied commit(s) into your checked out branch. At any time you can press `<esc>` to cancel the selection. |
128
138
|`` <c-t> ``| Open external diff tool (git difftool) ||
129
139
|`` * ``| Select commits of current branch ||
140
+
|`` 0 ``| Focus main view ||
130
141
|`` <enter> ``| View files ||
131
142
|`` w ``| View worktree options ||
132
143
|`` / ``| 検索を開始 ||
@@ -148,6 +159,7 @@ If you would instead like to start an interactive rebase from the selected commi
148
159
|`` ` ``| ファイルツリーの表示を切り替え | Toggle file view between flat and tree layout. Flat layout shows all file paths in a single list, tree layout groups files by directory. |
149
160
|`` - ``| Collapse all files | Collapse all directories in the files tree |
150
161
|`` = ``| Expand all files | Expand all directories in the file tree |
162
+
|`` 0 ``| Focus main view ||
151
163
|`` / ``| 検索を開始 ||
152
164
153
165
## コミットメッセージ
@@ -192,6 +204,7 @@ If you would instead like to start an interactive rebase from the selected commi
192
204
|`` P ``| タグをpush | Push the selected tag to a remote. You'll be prompted to select a remote. |
193
205
|`` g ``| Reset | View reset options (soft/mixed/hard) for resetting onto selected item. |
194
206
|`` <c-t> ``| Open external diff tool (git difftool) ||
207
+
|`` 0 ``| Focus main view ||
195
208
|`` <enter> ``| コミットを閲覧 ||
196
209
|`` w ``| View worktree options ||
197
210
|`` / ``| Filter the current view by text ||
@@ -226,6 +239,7 @@ If you would instead like to start an interactive rebase from the selected commi
226
239
|`` f ``| Fetch | Fetch changes from remote. |
227
240
|`` - ``| Collapse all files | Collapse all directories in the files tree |
228
241
|`` = ``| Expand all files | Expand all directories in the file tree |
242
+
|`` 0 ``| Focus main view ||
229
243
|`` / ``| 検索を開始 ||
230
244
231
245
## ブランチ
@@ -251,6 +265,7 @@ If you would instead like to start an interactive rebase from the selected commi
251
265
|`` R ``| ブランチ名を変更 ||
252
266
|`` u ``| View upstream options | View options relating to the branch's upstream e.g. setting/unsetting the upstream and resetting to the upstream. |
253
267
|`` <c-t> ``| Open external diff tool (git difftool) ||
268
+
|`` 0 ``| Focus main view ||
254
269
|`` <enter> ``| コミットを閲覧 ||
255
270
|`` w ``| View worktree options ||
256
271
|`` / ``| Filter the current view by text ||
@@ -277,6 +292,9 @@ If you would instead like to start an interactive rebase from the selected commi
277
292
|-----|--------|-------------|
278
293
|`` mouse wheel down (fn+up) ``| 下にスクロール ||
279
294
|`` mouse wheel up (fn+down) ``| 上にスクロール ||
295
+
|`` <tab> ``| パネルを切り替え | Switch to other view (staged/unstaged changes). |
296
+
|`` <esc> ``| Exit back to side panel ||
297
+
|`` / ``| 検索を開始 ||
280
298
281
299
## メインパネル (Patch Building)
282
300
@@ -348,6 +366,7 @@ If you would instead like to start an interactive rebase from the selected commi
348
366
|`` s ``| 並び替え ||
349
367
|`` g ``| Reset | View reset options (soft/mixed/hard) for resetting onto selected item. |
350
368
|`` <c-t> ``| Open external diff tool (git difftool) ||
369
+
|`` 0 ``| Focus main view ||
351
370
|`` <enter> ``| コミットを閲覧 ||
352
371
|`` w ``| View worktree options ||
353
372
|`` / ``| Filter the current view by text ||
@@ -366,6 +385,7 @@ If you would instead like to start an interactive rebase from the selected commi
|`` <c-t> ``| Open external diff tool (git difftool) ||
67
67
|`` * ``| Select commits of current branch ||
68
+
|`` 0 ``| Focus main view ||
68
69
|`` <enter> ``| 커밋 보기 ||
69
70
|`` w ``| View worktree options ||
70
71
|`` / ``| Filter the current view by text ||
71
72
73
+
## Secondary
74
+
75
+
| Key | Action | Info |
76
+
|-----|--------|-------------|
77
+
|`` <tab> ``| 패널 전환 | Switch to other view (staged/unstaged changes). |
78
+
|`` <esc> ``| Exit back to side panel ||
79
+
|`` / ``| 검색 시작 ||
80
+
72
81
## Stash
73
82
74
83
| Key | Action | Info |
@@ -78,6 +87,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
78
87
|`` d ``| Drop | Remove the stash entry from the stash list. |
79
88
|`` n ``| 새 브랜치 생성 | Create a new branch from the selected stash entry. This works by git checking out the commit that the stash entry was created from, creating a new branch from that commit, then applying the stash entry to the new branch as an additional commit. |
80
89
|`` r ``| Rename stash ||
90
+
|`` 0 ``| Focus main view ||
81
91
|`` <enter> ``| View selected item's files ||
82
92
|`` w ``| View worktree options ||
83
93
|`` / ``| Filter the current view by text ||
@@ -96,6 +106,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
|`` <c-t> ``| Open external diff tool (git difftool) ||
98
108
|`` * ``| Select commits of current branch ||
109
+
|`` 0 ``| Focus main view ||
99
110
|`` <enter> ``| View selected item's files ||
100
111
|`` w ``| View worktree options ||
101
112
|`` / ``| 검색 시작 ||
@@ -140,6 +151,9 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
140
151
|-----|--------|-------------|
141
152
|`` mouse wheel down (fn+up) ``| 아래로 스크롤 ||
142
153
|`` mouse wheel up (fn+down) ``| 위로 스크롤 ||
154
+
|`` <tab> ``| 패널 전환 | Switch to other view (staged/unstaged changes). |
155
+
|`` <esc> ``| Exit back to side panel ||
156
+
|`` / ``| 검색 시작 ||
143
157
144
158
## 메인 패널 (Patch Building)
145
159
@@ -201,6 +215,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
201
215
|`` R ``| 브랜치 이름 변경 ||
202
216
|`` u ``| View upstream options | View options relating to the branch's upstream e.g. setting/unsetting the upstream and resetting to the upstream. |
203
217
|`` <c-t> ``| Open external diff tool (git difftool) ||
218
+
|`` 0 ``| Focus main view ||
204
219
|`` <enter> ``| 커밋 보기 ||
205
220
|`` w ``| View worktree options ||
206
221
|`` / ``| Filter the current view by text ||
@@ -254,6 +269,7 @@ _Legend: `<c-b>` means ctrl+b, `<a-b>` means alt+b, `B` means shift+b_
254
269
|`` s ``| Sort order ||
255
270
|`` g ``| View reset options | View reset options (soft/mixed/hard) for resetting onto selected item. |
256
271
|`` <c-t> ``| Open external diff tool (git difftool) ||
272
+
|`` 0 ``| Focus main view ||
257
273
|`` <enter> ``| 커밋 보기 ||
258
274
|`` w ``| View worktree options ||
259
275
|`` / ``| Filter the current view by text ||
@@ -293,6 +309,7 @@ If you would instead like to start an interactive rebase from the selected commi
293
309
|`` C ``| 커밋을 복사 (cherry-pick) | Mark commit as copied. Then, within the local commits view, you can press `V` to paste (cherry-pick) the copied commit(s) into your checked out branch. At any time you can press `<esc>` to cancel the selection. |
294
310
|`` <c-t> ``| Open external diff tool (git difftool) ||
295
311
|`` * ``| Select commits of current branch ||
312
+
|`` 0 ``| Focus main view ||
296
313
|`` <enter> ``| View selected item's files ||
297
314
|`` w ``| View worktree options ||
298
315
|`` / ``| 검색 시작 ||
@@ -314,6 +331,7 @@ If you would instead like to start an interactive rebase from the selected commi
314
331
|`` ` ``| 파일 트리뷰로 전환 | Toggle file view between flat and tree layout. Flat layout shows all file paths in a single list, tree layout groups files by directory. |
315
332
|`` - ``| Collapse all files | Collapse all directories in the files tree |
316
333
|`` = ``| Expand all files | Expand all directories in the file tree |
334
+
|`` 0 ``| Focus main view ||
317
335
|`` / ``| 검색 시작 ||
318
336
319
337
## 커밋메시지
@@ -334,6 +352,7 @@ If you would instead like to start an interactive rebase from the selected commi
334
352
|`` P ``| 태그를 push | Push the selected tag to a remote. You'll be prompted to select a remote. |
335
353
|`` g ``| 초기화 | View reset options (soft/mixed/hard) for resetting onto selected item. |
336
354
|`` <c-t> ``| Open external diff tool (git difftool) ||
355
+
|`` 0 ``| Focus main view ||
337
356
|`` <enter> ``| 커밋 보기 ||
338
357
|`` w ``| View worktree options ||
339
358
|`` / ``| Filter the current view by text ||
@@ -368,6 +387,7 @@ If you would instead like to start an interactive rebase from the selected commi
368
387
|`` f ``| Fetch | Fetch changes from remote. |
369
388
|`` - ``| Collapse all files | Collapse all directories in the files tree |
370
389
|`` = ``| Expand all files | Expand all directories in the file tree |
0 commit comments