This is the repository I use to store my custom Emacs configuration, so to easily keep my different Emacs installations (home, office, virtual machines, etc.) in synch without much effort, and also to version it in case some new extension or configuration i may add ends up breaking everything.
Not much to do here. Just clone the repository with name .emacs.d/ in your home, and copy the configuration file ~/.emacs.d/.emacs inside your home as well.
If you want to use another directory name, you'll have to edit ~/.emacs accordingly.
To update, just call git pull inside ~/.emacs.d/.
Windows configuration:
windows.elandrevive.elto save and resume windows configuration. Code added to save at quit, and resume at startup automatically.- Default windows size set at startup to a decent value.
- Disabled splash screen.
Command line interface:
- Emacs server is started by default when using window system (when you don't use Emacs inside the command line). This is useful to open new files inside the existing Emacs frame from the command line, instead of opening a new frame each time (default behaviour when calling simply
emacs). To do this you can callemacsclient -n filename. I actually aliased it tocemacsadding this line to my.zshrc:
alias cemacs="emacsclient -n"
Editing:
autopair.elto automatically close open parenthesis. Matching parenthesis highlighted.- Automatically indenting at newline. Indenting with spaces instead of tabs.
- Showing line numbers at startup.
cua-modeto enable common Ctrl+C, Ctrl+V, Ctrl+X, Ctrl+Z shortcuts (using the system clipboard), and to have backspace delete selected region.- Smart beginning of line:
homekey jumps to the first non-white character. If point is already there, jump to the actual beginning of line. - Smart current line comment with shortcut Ctrl+,.
Theme:
zenburntheme is used.
WARNING. If you are using version 24.*, substitute line
(add-to-list 'load-path "~/.emacs.d/themes/")
with
(add-to-list 'custom-theme-load-path "~/.emacs.d/themes/")
inside file .emacs.
Modes:
php-modejs2-modeweb-modelinked to.phtml,.tpl,.jsp,.aspx,.erb,.mustache,.djhtmland.htmlextensions. Set indent offset to 4 spaces, and current element highlighting.scss-mode(auto-compile disabled, since i use Grunt for it)puppet-mode