Skip to content
Dotemacs (.emacs) configuration file
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.emacs
README.org
not-pusheen.gif Added not-pusheen.gif Jun 3, 2019
not-pusheen2.gif
pusheen.gif Trying to get small gif working Jun 3, 2019

README.org

Dotemacs (.emacs)

Pusheen gif to make this approachable

pusheen.gif

What does my Emacs look like?

not-pusheen2.gif

What is Emacs?

Emacs is a free (as in freedom) open source text editor.

This repository contains my .emacs file which is the main config file for Emacs.

I have tried to keep my .emacs file as clean and well-documented as possible, but I have to admit I am not that knowledgeable in Lisp and so my .emacs contains code that I shamelessly copied without understanding.

Emacs vs Vim

As is obvious from the large amount of evil bindings, I come from Vim. After a stint of Spacemacs (which I didn’t like) I switched to Emacs completely solely for org-mode and I don’t regret a thing. Both Vim and Emacs have great features so why not take the best of both of worlds?

Some interesting parts

Instead of having you trudge through my whole .emacs I would like to show you some pieces of my configuration file that you might find interesting.

Bind C-x v to open .emacs

;; Bind =C-x v= to open ~/.emacs, remnant from my Vim times where
;; =<Leader> v= would open my ~/.vimrc
(global-set-key (kbd "\C-xv") (lambda () (interactive)
  (find-file "~/.emacs")
  (message "Opened:  %s" (buffer-name))))

For some reason C-u (which is half a page up in Vim-speak) doesn’t work by default. I think this has to do with Emacs using C-u as an important pre-fix. This fixes that

;; Makes C-u scroll up (see: https://stackoverflow.com/questions/14302171/ctrlu-in-emacs-when-using-evil-key-bindings)
(setq evil-want-C-u-scroll t)

And possibly the most important one is this one: Vim-like paragraph movements don’t work out of the box. This creates that Vim-like paragraph feel which we all know and love

;; Make evil paragraphs behave like vim paragraphs
;; See: https://emacs.stackexchange.com/questions/38596/make-evil-paragraphs-behave-like-vim-paragraphs
(with-eval-after-load 'evil
  (defadvice forward-evil-paragraph (around default-values activate)
    (let ((paragraph-start (default-value 'paragraph-start))
          (paragraph-separate (default-value 'paragraph-separate)))
      ad-do-it)))
You can’t perform that action at this time.