DoomEmacs
通过使用 evil
模式,很好地结合了 Emacs
与 Vim
,非常适合入坑。
安装
安装 Emacs
1
2
3
4
|
sudo add-apt-repository ppa:ubuntuhandbook1/emacs
sudo apt install emacs emacs-common
emacs --version
|
安装 DoomEmacs
1
2
3
4
5
|
git clone --depth 1 https://github.com/doomemacs/doomemacs ~/.config/emacs
~/.config/emacs/bin/doom install
## 如果有修改,需要执行 sync
doom sync
|
配置
需要在环境变量中指定 DOOMDIR
1
2
|
export DOOMDIR=~/.doom.d
cp templates/config.example.el ~/.doom.d/config.el
|
~/.doom.d/config.el
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
;; ----------------------------------------------------------------------------
;; $DOOMDIR/config.el -*- lexical-binding: t; -*-
;; Place your private configuration here! Remember, you do not need to run 'doom
;; sync' after modifying this file!
;; ----------------------------------------------------------------------------
;; theme: ---------------------------------------------------------------------
;; There are two ways to load a theme. Both assume the theme is installed and
;; available. You can either set `doom-theme' or manually load a theme with the
;; `load-theme' function. This is the default:
(setq doom-theme 'doom-tokyo-night)
;; Leader: --------------------------------------------------------------------
;; DoomEmacs default leader is `<Space>`, here I change it to `;`
;; since it is much more easy
(setq doom-leader-key ";"
doom-leader-alt-key ";")
|
使用