diff options
author | Guangxiong Lin <[email protected]> | 2022-02-22 09:52:17 +0800 |
---|---|---|
committer | Guangxiong Lin <[email protected]> | 2022-02-22 09:52:17 +0800 |
commit | 32ed338843935a257bfae23ca9cfe905dff0b9a0 (patch) | |
tree | 64ce0fa41e36e4aa5cf798384075661ab72cddda | |
parent | 620ae93bb23a458a215cb99f823538a9c2cf385d (diff) | |
download | dotfiles-32ed338843935a257bfae23ca9cfe905dff0b9a0.tar.gz dotfiles-32ed338843935a257bfae23ca9cfe905dff0b9a0.tar.bz2 dotfiles-32ed338843935a257bfae23ca9cfe905dff0b9a0.zip |
Set emacs auto save directory
-rw-r--r-- | .emacs.d/lisp/init-misc.el | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/.emacs.d/lisp/init-misc.el b/.emacs.d/lisp/init-misc.el index 71a5d7e..0a0bdf7 100644 --- a/.emacs.d/lisp/init-misc.el +++ b/.emacs.d/lisp/init-misc.el @@ -4,8 +4,18 @@ (when (version<= "26.0.50" emacs-version) (global-display-line-numbers-mode)) (setq vc-follow-symlinks t) -(setq backup-directory-alist - `(("." . ,(concat user-emacs-directory "backups")))) + +(setq + backup-by-copying t + delete-old-versions t + kept-new-versions 10 + kept-old-versions 2 + version-control t + backup-directory-alist `(("." . ,(concat user-emacs-directory "backups")))) + +(setq auto-save-file-name-transforms + `((".*" "~/.emacs.d/backups/" t))) + (setq-default fill-column 72) (menu-bar-mode -1) (xterm-mouse-mode 1) ;; Enable mouse |