Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
evil-mode lightning talk emacs nyc


who am i?

Bailey Ling


github/bling @blingcoder

some things i’ve done







modal editing

this seems to be what people think of when you mention vim, but…

emacs is modal too


n and p move up and down i and d to install or delete and x to execute


n and p move up and down j jumps to a buffer with completion m marking files to perform an action afterwards


every major-mode will add useful goodies in here

so why modal for editing?

because as developers, we are editing text most of the time, not writing

that’s why it’s called ‘normal’ mode, and is the default

it’s the better ergonomic choice. there is no such thing as vim pinky.

for me, i hate where ALT is. and all the cool/important stuff is with Meta

back to basics

let’s start with emacs motions

C-f, C-b, M-f, M-b, M-{, M-}, etc.

and some manipulation commands

killing lines: C-k killing words: M-d killing sentences: M-k

anything more complicated, is a bit more painful

C-SPC, <motion>, <operation>

for example, delete all the text inside (these parentheses with cursor here)

emacs users tend to think in terms of code, not text. they would probably backward-kill-sexp followed by kill-sexp

it’s not uncommon for emacs users to create functions for commonly used text manipulation

composibility is a first-class citizen in vim

what does that mean?


+ motion

+ text object

= awesome

operator + motion + text-object = awesome

operator: [c]hange, [d]elete, [y]ank motion: [i]nner, [a]round text-object: [w]ord, [p]aragraph, [s]entence, [b]lock

easily memorable. you all know how to use vim now, it’s just muscle memory from here.

i know what C-x 5 2 does, do you?

coding can be repetitive

dot operator to the rescue

if i like vim so much, why emacs?


deleting words with the cursor in the middle

changing inside of c-style function block

changing inside of arguments





Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment