fork-dev / TrackerWin

Bug and issue tracker for Fork for Windows
461 stars 10 forks source link

[Feature request/regression] Ctrl+shift+C no longer focuses commit view, and various other commit keybinding improvements #1203

Open rhys-vdw opened 3 years ago

rhys-vdw commented 3 years ago

I've discovered that the official doc (#333) comment lists this as ctrl+1, but I've been using ctrl+shift+C out of habit due to it being the shortcut for other git clients. Am I confused or was this recently removed?

I generally have a few complaints about keyboard support in this process too:

In any case I would like to request that this shortcut is reinstated to focus changes view. My argument being that it is (in my experience) a standard hotkey and is therefore very discoverable.

Currently you can strike the hotkey again (as documented in #333) to take you to the commit subject (awesome) but then there's no way to get back. It would be great if this pressing this shortcut while focusing on the commit subject/description would focus you back on the "unstaged" view.

Also there is some sort of problem getting from unstaged to staged at the moment. I can press "tab" from unstaged and it puts an outline around the first unstaged item.

But when I press enter it affects the item I had selected in unstaged:

  1. Starting state: image

  2. Press tab gives weird fake-selection thing: image

  3. Press enter affects unselected item from previous pane: image

Thanks for the best git client on the market. 🙏

DanPristupov commented 3 years ago

I've been using ctrl+shift+C out of habit due to it being the shortcut for other git clients. Am I confused or was this recently removed?

Yes, this change was mentioned in the release notes:

Keyboard shortcuts: Ctrl+C to copy SHA, Ctrl+Shift+C to copy commit info

Also there is some sort of problem getting from unstaged to staged at the moment. I can press "tab" from unstaged and it puts an outline around the first unstaged item.

We will have a look at this. As a workaround, you can press an arrow key to make the selection "normal"

Otiel commented 3 years ago

Currently you can strike the hotkey again (as documented in #333) to take you to the commit subject (awesome) but then there's no way to get back. It would be great if this pressing this shortcut while focusing on the commit subject/description would focus you back on the "unstaged" view.

I would love as well to have a shortcut to go from the "Commit subject" textbox to the "Unstaged" area.

Hitting Ctrl1 to go back and forth between those two controls would be nice.

DanPristupov commented 3 years ago

@Otiel Shift+Tab?

Otiel commented 3 years ago

Hmm that works, but it's not as easy as hitting Ctrl1 when you're used to it.

Consider this:

Plus, it's weird to be able to use Ctrl1 to go from the "Unstaged" area to the "Commit subject" textbox, but to have to use ShiftTab to go back.

rhys-vdw commented 3 years ago

Actually in testing now, it seems that ctrl1 does not focus staging even when coming from another view. Also tab and shifttab have the strange not-quite-focused behaviour I describe in the issue above, and don't always focus the same pane (will jump to "staged" if there is am enter there).

rhys-vdw commented 3 years ago

@DanPristupov

We will have a look at this. As a workaround, you can press an arrow key to make the selection "normal"

This is only true when you have more than one entry in the pane.

rhys-vdw commented 3 years ago

So here is the main scenario that seems broken to me right now. It is my most common interraction with fork, and the one I would like to remove mouse from entirely: Committing all unstaged changes. (equivalent of git add -A; git commit -m "...')

I assume this sequence:

  1. ctrl1 to jump to "changes" view
  2. ctrla to select all unstaged changes
  3. enter to stage
  4. ctrl1 to jump to commit field
  5. Enter title, then tab for description
  6. ctrlenter to commit

This what I get in practise: Starting state: image

ctrl1 to jump to "changes" view. Note that selection is still on branches pane image

ctrla to select all unstaged changes Oh no something completely undesirable has happened! image

So to me this is either unattainable, or the keyboard shortcuts are a bit too obscure/unconventional.

An extension of this would be an easy way to, after step 3, move back and forth between staged and unstaged and move files. e.g. I can look and say 'oh wait, no I want to unstage this file before I commit'.

I think one nice way to address this is as simple as pressing down arrow on the bottom "unstaged" entry will jump you to the first staged and vice-versa. Currently that keystroke is ignored completely.

Anyway, from my perspective this is the scenario to get right. I've used Tower and SourceTree in the past and have been able to do all of this from keyboard. Tower in particular is very similar and gets this right, so it might be a useful reference.

Hope this is helpful and resonates with the team/other users.