Settings forked from magnars/.emacs.d
Ensure to toast your .emacs file if you have one. Also delete anything inside your .emacs.d.
To grab all the dependencies:
git clone --recursive git://github.com:mjamesruggiero/.emacs.d.git
The first time you start emacs, it will install some additional packages that are best handled by the package manager.
brew install emacs
I removed the stock emacs version from Mac OS X 10.9 in /usr/bin
I manually installed Emacs cocoa binary into /Applications.
-
Meta key is bound to command on a Mac.
-
Key bindings are listed in settings/key-bindings.el
-
You quit emacs with
C-x r q
, mnemonic Really Quit. -
Find file in project with
C-x o
, in dir withC-x C-f
, recent withC-x f
-
Help is bound to
F1
.C-h
is rebound to backspace, like in the shell. -
Autocomplete with
C-.
(autocomplete entire lines withC-:
) -
Expand-region is bound to
C-'
-
Undo with
C-_
orC-/
and redo withM-_
. Watch the undo-tree withC-x u
-
Quickly jump anywhere in the buffer with
M-g
then the starting letter of a word. Press the letter highlighted to go there. -
Indent and clean up white space in the entire buffer with
C-c n
C
Shorthand for the ctrl-keyM
Shorthand for the meta-key (bound to cmd on my mac settings)S
Shorthand for the shift-key
C-x C-f
Open a file. Starts in the current directoryC-x f
Open a recently visited fileC-x o
Open a file in the current project (based on .git ++)C-x C-s
Save this fileC-x C-w
Save as ...C-x C-j
Jump to this files' current directoryC-x b
Switch to another open file (buffer)C-x C-b
List all open files (buffers)
C-space
Start marking stuff. C-g to cancel. Navigate however you desire to expand the region, you don't have to press anything to close it.C-w
Cut (aka kill)C-k
Cut till end of lineM-w
CopyC-y
Paste (aka yank)M-y
Cycle last paste through previous killsC-x C-y
Choose what to paste from previous kills
C-g
Quit out of whatever mess you've gotten yourself intoM-x
Run a command by nameC-.
AutocompleteC-_
UndoM-_
RedoC-x u
Show the undo-treeC-x m
Open magit. It's a magical git interface for emacs
C-arrow
Move past words/paragraphsC-a
Go to start of lineC-e
Go to end of lineM-g M-g
Go to line numberC-x C-i
Go to symbolC-s
Search forward. PressC-s
again to go further.C-r
Search backward. PressC-r
again to go further.
C-x 0
Close this windowC-x 1
Close other windowsC-x 2
Split window horizontallyC-x 3
Split window verticallyS-arrow
Jump to window to the left/right/up/down
F1 t
Basic tutorialF1 k
Help for a keybindingF1 r
Emacs' extensive documentation
C-x m
.s
to stage,c
to commit.C-c C-c
to finish commit msg buffer.