< Return to Video

Emacs Rocks! Episode 10: Jumping around

  • 0:01 - 0:03
    Welcome back to emacs rocks
  • 0:03 - 0:10
    Today we're taking a look at two of my favorite ways of jumping around
  • 0:13 - 0:15
    First out is ace-jump-mode
  • 0:15 - 0:21
    I want to jump to the word "strict" in that "use strict" declaration at the top
  • 0:21 - 0:24
    Wow, that was fast!
  • 0:24 - 0:30
    Now, the third instance of the word rows in that return statement
  • 0:30 - 0:33
    Again, straight to it!
  • 0:33 - 0:38
    And I can jump straight back to where I started by popping the mark
  • 0:38 - 0:40
    Okay, let's do that in slower motion
  • 0:40 - 0:42
    I initialize ace-jump-mode,
  • 0:42 - 0:47
    and then type the starting letter of the word I want to jump to: S
  • 0:47 - 0:52
    notice how everything is greyed out, and the S is replaced by a red A
  • 0:52 - 0:54
    I press A
  • 0:54 - 0:57
    Next up is the word rows, starts with R
  • 0:57 - 1:01
    See how all the words starting with R has its own letter?
  • 1:01 - 1:05
    The one I want is number five from the top, or E
  • 1:05 - 1:09
    Again, pop mark to get back
  • 1:12 - 1:14
    I can also jump into the middle of a word
  • 1:14 - 1:17
    by giving ace-jump-mode a prefix argument
  • 1:17 - 1:23
    Like to the word "shape" in validateNonEmptyShape
  • 1:24 - 1:26
    That was ace-jump-mode
  • 1:26 - 1:29
    And it is ... ace!
  • 1:30 - 1:32
    Next up is ido-imenu
  • 1:32 - 1:35
    Depending on your major mode, it find symbols in the buffer
  • 1:35 - 1:39
    and lets you jump quickly to them.
  • 1:42 - 1:45
    I'd like to use pop-mark to jump back here aswell
  • 1:45 - 1:48
    but ido-imenu doesn't set the mark before jumping.
  • 1:48 - 1:51
    Luckily we're using a truly extensible editor,
  • 1:51 - 1:53
    so I fixed that.
  • 1:54 - 1:57
    Here's the script
  • 1:57 - 2:00
    and you can find it at this gist.
  • 2:04 -
    Thanks for watching emacs rocks.
Title:
Emacs Rocks! Episode 10: Jumping around
Description:

http://emacsrocks.com - Rocking emacs tricks and tips screencast.

Follow me on twitter: @emacsrocks

more » « less
Video Language:
English
Duration:
02:08
magnarsveen added a translation

English subtitles

Revisions