Welcome back to emacs rocks
Today we're taking a look at two of my favorite ways of jumping around
First out is ace-jump-mode
I want to jump to the word "strict" in that "use strict" declaration at the top
Wow, that was fast!
Now, the third instance of the word rows in that return statement
Again, straight to it!
And I can jump straight back to where I started by popping the mark
Okay, let's do that in slower motion
I initialize ace-jump-mode,
and then type the starting letter of the word I want to jump to: S
notice how everything is greyed out, and the S is replaced by a red A
I press A
Next up is the word rows, starts with R
See how all the words starting with R has its own letter?
The one I want is number five from the top, or E
Again, pop mark to get back
I can also jump into the middle of a word
by giving ace-jump-mode a prefix argument
Like to the word "shape" in validateNonEmptyShape
That was ace-jump-mode
And it is ... ace!
Next up is ido-imenu
Depending on your major mode, it find symbols in the buffer
and lets you jump quickly to them.
I'd like to use pop-mark to jump back here aswell
but ido-imenu doesn't set the mark before jumping.
Luckily we're using a truly extensible editor,
so I fixed that.
Here's the script
and you can find it at this gist.
Thanks for watching emacs rocks.