Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shift modifier on the Commit Details View topological navigation keystrokes #383

Closed
SimonAlfie opened this issue Sep 18, 2020 · 4 comments
Closed
Assignees
Labels
feature request Feature request
Projects
Milestone

Comments

@SimonAlfie
Copy link

SimonAlfie commented Sep 18, 2020

The current commit info contains the parent commit(s) as commit hash links, which can be clicked to jump to the parent commit in Git Graph. It would be very useful if the child commit(s) were also included in the same manner, making it as easy to jump forwards to the children as it is back to the parents.

Currently you can jump back to a parent but then have to scroll up to go forward to the child, this is particularly problematic if you are looking at merges (especially merges of very old commits), and you go down the wrong history path.

@SimonAlfie SimonAlfie added the feature request Feature request label Sep 18, 2020
@mhutchie
Copy link
Owner

Hi @SimonAlfie,

The Commit Details View displays information about a commit, primarily obtained by git show. Git doesn't store a commits children, only it's parents - hence why I don't display a list of children (as that information is not available from Git). Although it would be possible to infer the children of a commit by scanning the loaded commits for commits with the desired parent, this is very misleading as it's possible that the commit has additional children that are not within the loaded commits (e.g. a child is on a branch that has been filtered out). As I definitely don't want to mislead any users, who rely on the data being complete, unfortunately it's simply not possible to add the children to the Commit Details View.

However, are you aware of the following keyboard shortcuts that allow you to easily move between commits when the Commit Details View is open? I believe the keystrokes CTRL/CMD + Up / CTRL/CMD + Down would help you in the situation you describe, providing fast and accurate graph traversal without scrolling.

When the Commit Details View is open on a commit:

  • Up / Down: The Commit Details View will be opened on the commit directly above or below it on the Git Graph View.
  • CTRL/CMD + Up / CTRL/CMD + Down: The Commit Details View will be opened on its child or parent commit on the same branch.

(from the readme)

I'll close this issue, as it's simply not possible to accurately obtain the data required for this feature request.

@SimonAlfie
Copy link
Author

Hi @mhutchie

Thanks for the quick response. I can see your point about the information not being thee in the git command. So its not easy to obtain.

Unfortunately the workaround you suggest does not work as is only follows the current branch. What happens in a fork (going forwards with Ctrl-Up) or merge (going backwards with Ctrl-Down)? You can only follow one path. Maybe a Ctrl-Shift-Up or Ctrl-Shift-Down to follow the alternate path?

Agreed it is a nicety not essential. I am really just suggesting a really nice feature from GitExtensions.

@mhutchie
Copy link
Owner

Hi @SimonAlfie,

I really like your suggestion of providing CTRL/CMD + SHIFT + Up / CTRL/CMD + SHIFT + Down keystrokes to follow an alternative parent, I think many users would find it valuable.

I'll include this in the next release of Git Graph.

@mhutchie mhutchie reopened this Sep 18, 2020
@mhutchie mhutchie added this to To Do in Git Graph via automation Sep 18, 2020
@mhutchie mhutchie added this to the v1.27.0 milestone Sep 18, 2020
@mhutchie mhutchie changed the title Add child commit hashes to currently viewed commit info as hyperlinks Shift modifier on the Commit Details View topological navigation keystrokes Sep 18, 2020
@mhutchie mhutchie moved this from To Do to In Progress in Git Graph Sep 18, 2020
mhutchie added a commit that referenced this issue Sep 19, 2020
@mhutchie
Copy link
Owner

This will be available in v1.27.0.

If you'd like to use it before the next release, you can download v1.27.0-beta.1, and install it following the instructions provided here.

Git Graph automation moved this from In Progress to Ready For Release Sep 19, 2020
@mhutchie mhutchie moved this from Ready For Release to Released in Git Graph Nov 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Feature request
Projects
Git Graph
Released
Development

No branches or pull requests

2 participants