summaryrefslogtreecommitdiff
path: root/lisp/init-elisp.el
blob: 4a7750fd5e9593ae84f98b384d1880626840c93b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
(require-package 'paredit)

(autoload 'enable-paredit-mode "paredit"
  "Turn on pseudo-structural editing of Lisp code."
  t)

(add-hook 'emacs-lisp-mode-hook 'enable-paredit-mode)

(eval-after-load 'paredit
  '(progn
    (define-key paredit-mode-map (kbd "C-,") 'paredit-forward-slurp-sexp)
    (define-key paredit-mode-map (kbd "C-.") 'paredit-forward-barf-sexp)
    (define-key paredit-mode-map (kbd "C-M-,") 'paredit-backward-slurp-sexp)
    (define-key paredit-mode-map (kbd "C-M-.") 'paredit-backward-barf-sexp)
    (diminish 'paredit-mode "Pe")))

(provide 'init-elisp)