Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable,...
Transcript of Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable,...
![Page 1: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/1.jpg)
Being Productive With EmacsPart 1
Phil Sungsipbiap[email protected]
http://stuff.mit.edu/iap/emacsSpecial thanks to Piaw Na and Arthur Gleckler
![Page 2: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/2.jpg)
“Emacs is the extensible, customizable, selfdocumenting realtime display editor.”
![Page 3: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/3.jpg)
The many faces of Emacs
Emacs edits source code
![Page 4: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/4.jpg)
The many faces of Emacs
Emacs is a hex editorMx hexlfindfile
![Page 5: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/5.jpg)
The many faces of Emacs
Emacs does diffsMx ediffbuffers
![Page 6: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/6.jpg)
The many faces of Emacs
Emacs is a file managerMx dired
![Page 7: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/7.jpg)
The many faces of Emacs
Emacs is a shellMx shell
![Page 8: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/8.jpg)
The many faces of Emacs
Emacs is a mail/news clientMx gnus
![Page 9: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/9.jpg)
The many faces of Emacs
Emacs plays tetrisMx tetris
![Page 10: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/10.jpg)
Why Emacs? Provides an integrated environment
● Same editing commands available everywhere● Large set of tools available at all times● Move text between tasks easily
![Page 11: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/11.jpg)
Why Emacs? Easy to extend
● Elisp for customizing or adding new features● Extension code has the full power of Emacs● Dynamic environment: no restarting or recompiling
Portable
![Page 12: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/12.jpg)
Today's goal: get the flavor of Emacs● Getting started with Emacs● Editing tips● Demos of useful features● Common Emacs concepts
Later...● Advanced customization● Programming and extending Emacs with Elisp
Examples based onGNU Emacs 22
![Page 13: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/13.jpg)
Prerequisites (sort of) Emacs basic concepts
● Files, buffers, windows, frames Keyboard commands
● Key commands, prefix keys, Mx, the minibuffer● "Cx" means Ctrl+x"Mx" means Meta+x or Alt+x
Basic tasks● Opening and saving files, exiting Emacs
Take the tutorialto brush up:Ch t
![Page 14: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/14.jpg)
It's all about text manipulation Text in files
● grocery lists, HTML, code, ... Text outside of files
● shell, debugger, ... Text as a metaphor
● dired, gnus, ...
![Page 15: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/15.jpg)
Text as a metaphor: dired
After editing names in this buffer, Cx Cs renames the
modified files
M-x wdired-change-to-wdired-modeafter opening any directory
![Page 16: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/16.jpg)
Moving around in buffers By character or line
Cp
Cn
Cb Cf
![Page 17: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/17.jpg)
Moving around in buffers Beginning, end of line
● Ca, Ce By word
● Mf, Mb By sentence
● Ma, Me
By screen● Cv, Mv
Beginning, end of buffer● M<, M>
Go to line #● Mg g
![Page 18: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/18.jpg)
Moving around in buffers Move multiple lines forward, backward
● Example: Cu 10 Cp (back 10 lines)● Cu prefix generalizes to other commands
Search for text● Cs, Cr
Exchange point (cursor) and mark● Cx Cx
![Page 19: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/19.jpg)
Killing ("cutting") text Kill line
● Ck
Kill many lines● Cu 10 Ck (10 lines)● Cu Ck (4 lines)● Cu Cu Ck (16 lines)
![Page 20: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/20.jpg)
Killing ("cutting") text Kill region
● Cw
Save without killing● Mw
Kill sentence● Mk
Kill ("zap") to next occurrence of character● Mz CHAR
![Page 21: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/21.jpg)
Yanking ("pasting") text Yank
● Cy
Yank earlier killed text● My (once or more after Cy)
The kill ring● Almost all commands which delete text save it for
possible later retrieval
![Page 22: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/22.jpg)
The mark
When you...● Cspc
● M< or M>● Search for text● Yank text● Insert a buffer
the mark is set to...● where you are● where you were● where you started● start of inserted text● start of inserted text
Remembers a previous cursor position● Cx Cx to swap point (cursor) and mark
![Page 23: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/23.jpg)
The mark The mark ring
● Move to a previous mark: Cu CSPC Mark and point are also used to delineate 'the
region'● Many commands operate on the text in the region● Set region by setting mark, then moving point
![Page 24: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/24.jpg)
Undo Undo previous actions
● C/ or C_ or Cx u Undo within current region
● Cu C/
![Page 25: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/25.jpg)
The undo model, illustrated
A B C D
![Page 26: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/26.jpg)
The undo model, illustrated
A B C D
These states are accessible with 'undo'
![Page 27: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/27.jpg)
The undo model, illustrated
A B C D
Undo some of your actions...
These states are accessible with 'undo'
These states are accessible with 'redo'
This is how most editors other than emacs work:
![Page 28: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/28.jpg)
The undo model, illustrated
A B C D
Now do something else...
C'
This is how most editors other than emacs work:
These states are accessible with 'undo'
These states are no longer accessible!
![Page 29: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/29.jpg)
The undo model, illustrated
A B C D
How emacs handles this situation
C'
The list of states is 'folded' so that all previous actions,
including undos, are undoable
![Page 30: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/30.jpg)
Incremental search Search for text (like Firefox's "find as you type")
● Cs text Cs again to find next occurrence RET to stop at found occurrence Cg to cancel and go back to start of search
● Cr for reverse search● Many options available inside search;Ch k Cs to learn more
![Page 31: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/31.jpg)
Search history Search for previously searched string
● Cs Cs
Browse and edit previous queries● Cs then Mp, Mn
![Page 32: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/32.jpg)
Incremental search Search for regular expressions
● CMs regexp
● Regexp describes the form of what to look for● Syntax may be slightly different from other REs you
may have used Emacs REs are a superset of Perl REs
● Mx rebuilder can help you test complex regexps
![Page 33: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/33.jpg)
Searching and replacing Search and replace, asking for confirmation
● M% or Mx queryreplace Display all lines matching RE
● Mx occur
![Page 34: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/34.jpg)
RE search and replacement Mx replaceregexp
Replacement text can depend on found text! Replacement text gets these substitutions:
● \& (the matched string)● \1, \2, etc. (references to parts of matched string)● \# (number of matched lines so far)● \? (prompt user for what to enter)● \,(lispexpression ...)
![Page 35: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/35.jpg)
RE replacement example
Bill GatesSteve JobsEric SchmidtLarry Ellison
GATES, BillJOBS, SteveSCHMIDT, EricELLISON, Larry
Mx replaceregexp\(\w+\) \(\w+\)
with\,(upcase \2), \1
More tips at http://steve-yegge.blogspot.com/2006/06/shiny-and-new-emacs-22.html
![Page 36: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/36.jpg)
Integration with useful tools Shell
● Mx shell
Compile (invoke make)● Mx compile
Debug● Mx gdb
![Page 37: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/37.jpg)
Integration with useful tools Grep
● Mx grep, Mx rgrep Man page reader
● Mx woman
Invoke shell commands● Mx shellcommand,Mx shellcommandonregion
![Page 38: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/38.jpg)
...and then some Calculator
● Mx calc
Calendar● Mx calendar
Moon calendar● Mx phasesofmoon
![Page 39: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/39.jpg)
More helpful features TRAMP: open remote files over SSH
● Cx Cf /user@host:~/remote/file
VC: automatically deal with CVS, SVN, etc.● Mx vcnextaction to commit modified file● Mx vcdiff to view changes to current file
etags: name search/completion for source code
![Page 40: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/40.jpg)
Emacs server Use a single Emacs session for all editing Do this once: Mx serverstart
● or put (serverstart) in your .emacs file To edit a file:
● prompt% emacsclient file
● File opens in existing Emacs frame● Cx # when done editing
![Page 41: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/41.jpg)
Macros Remembers a fixed sequence of keys for later
repetition Start recording macro: Cx ( Stop recording macro: Cx ) Replay macro: Cx e
![Page 42: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/42.jpg)
Macro example
Bill GatesSteve JobsEric SchmidtLarry Ellison
GATES, BillJOBS, SteveSCHMIDT, EricELLISON, Larry
Define macro:Md Cd Mu , [SPC] Cy Cn Ca
"Remove first word and space, uppercase next word, insert comma and space afterward, reinsert first
word, move to beginning of next line"
Run macro repeatedly:Cx e e ...
![Page 43: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/43.jpg)
Narrowing Restricts view/editing in a buffer to a certain
region● Cx n n or Mx narrowtoregion to
narrow to region● Cx n w or Mx widen to restore ('widen')
![Page 44: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/44.jpg)
Registers Store current window configuration
● Cx r w REGISTER
Restore window configuration● Cx r j REGISTER
Registers can also store positions, text, numbers, file names...
REGISTER may be any letter or number
![Page 45: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/45.jpg)
Prefix arguments Sometimes used to indicate repetition
● Cu 10 Cf (forward 10 characters)● Cu Co (make 4 new lines)
Sometimes modify following command● C/ (undo) vs. Cu C/ (undo within region)● Mx shell vs. Cu Mx shell
A command's documentation (Ch f or Ch k) describes the effect of the prefix argument, if any
![Page 46: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/46.jpg)
Major modes Alters behavior, key bindings, and text display Switch mode in existing buffer:
● Mx javamode● Mx pythonmode● Mx fundamentalmode
Or, use another command to create buffer:● Mx shell● Mx dired
![Page 47: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/47.jpg)
Language major mode features Languagespecific indentation, syntax coloring Languagespecific features:
● Lisp: commands for manipulating sexpressions● Python: commands for (un)indenting blocks● HTML: insert/close tags; preview in web browser● Modes can define or redefine keys
![Page 48: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/48.jpg)
Minor modes Extra functionality you can turn on or off
● Any number of minor modes may be active at once● Independent of major mode functionality
Mx autofillmode Mx flyspellmode Mx followmode
![Page 49: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/49.jpg)
Global minor modes Offer completions for buffers, commands, etc.
● Mx icompletemode
Show all buffer names on Cx b:● Mx iswitchbmode
![Page 50: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/50.jpg)
Minibuffer input Common features whenever Emacs prompts
you to enter something● Most buffer editing, movement commands work● Browse previous inputs with Mn, Mp● Tabcompletion is often available
Mx evalexpression, Mx findfile, Mx switchtobuffer, ...
![Page 51: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/51.jpg)
Getting help with Emacs Help with key
● Ch k
Help with function● Ch f
Help with mode● Ch m
Show key bindings● Ch b
Help about help● Ch Ch
![Page 52: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/52.jpg)
Getting help with Emacs Apropos (search for command)
● Ch a
Help with prefix key● Ch (after prefix key)
Manuals● Mx info, then select emacs or efaq
![Page 53: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/53.jpg)
“In the event of an emergency” Cancel command
● Cg
Undo!● C/ or C_
What did I just do?● Mx viewlossage
![Page 54: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/54.jpg)
Common problems Delete not deleting?
● Mx normaleraseisbackspacemode
Keys with M not working?● Use ESC instead● ESC x instead of Mx● ESC Ct instead of CMt
![Page 55: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/55.jpg)
Migrating to Emacs From Windows applications
● Mx cuamode: recovers Cz, Cx, Cc, Cv for their usual purposes
From vi/vim● Mx vipermode
![Page 56: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/56.jpg)
Resources Emacs on Athena
● http://web.mit.edu/olh/Emacs/ Emacs reference card
● http://web.mit.edu/olh/Emacs/Refcard.pdf
![Page 57: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/57.jpg)
Invoking or installing Emacs emacs21 on Athena: athena% emacs emacs22 on Ubuntu/Debian:aptget install emacssnapshotgtk
emacs22 on Gentoo: emerge emacscvs emacs on Windows:
● http://ourcomments.org/Emacs/ EmacsW32Util.html
![Page 58: Being Productive With Emacs - Massachusetts … · “Emacs is the extensible, customizable, selfdocumenting realtime display editor.”](https://reader030.fdocuments.us/reader030/viewer/2022021712/5b90c03a09d3f2f1278c7a2d/html5/thumbnails/58.jpg)
Bonus: Being Unproductive With Emacs● Mx tetris, Mx hanoi, Mx doctor, ...
Next time: Emacs lisp● Customizing how Emacs works● Writing new functions, commands, and modes● Manipulating text programmatically● Altering behavior of existing commands