gitk: Make it easier to go quickly to a specific commit
authorIsmael Luceno <ismael@iodev.co.uk>
Wed, 15 Apr 2015 16:18:17 +0000 (13:18 -0300)
committerPaul Mackerras <paulus@samba.org>
Sun, 17 May 2015 04:23:12 +0000 (14:23 +1000)
Binds "g" to focus and clear the sha1 entry box.

Signed-off-by: Ismael Luceno <ismael@iodev.co.uk>
Signed-off-by: Paul Mackerras <paulus@samba.org>
gitk
diff --git a/gitk b/gitk
index 8c44e834ebbb68a710462b324dc27d4f9fafdfc0..68c6e701b03c2a1b39f454bf1b7a45fff5fe7675 100755 (executable)
--- a/gitk
+++ b/gitk
@@ -2568,6 +2568,7 @@ proc makewindow {} {
     bindkey b prevfile
     bindkey d "$ctext yview scroll 18 units"
     bindkey u "$ctext yview scroll -18 units"
+    bindkey g {$sha1entry delete 0 end; focus $sha1entry}
     bindkey / {focus $fstring}
     bindkey <Key-KP_Divide> {focus $fstring}
     bindkey <Key-Return> {dofind 1 1}
@@ -3071,6 +3072,7 @@ proc keys {} {
 [mc "<%s-F>            Find" $M1T]
 [mc "<%s-G>            Move to next find hit" $M1T]
 [mc "<Return>  Move to next find hit"]
+[mc "g         Go to commit"]
 [mc "/         Focus the search box"]
 [mc "?         Move to previous find hit"]
 [mc "f         Scroll diff view to next file"]