Emacs: combine auto-save and backup variables

This commit is contained in:
Marcel Kapfer 2018-02-23 09:32:23 +01:00
parent 550e2fe1cc
commit 603c7255ee
Signed by: mmk2410
GPG key ID: CADE6F0C09F21B09

View file

@ -55,11 +55,11 @@
;; Save backup files in ~/.emacs-autosaves/ ;; Save backup files in ~/.emacs-autosaves/
(defvar user-temporary-file-directory "~/.emacs-autosaves") (defvar user-temporary-file-directory "~/.emacs-autosaves")
(make-directory user-temporary-file-directory t) (make-directory user-temporary-file-directory t)
(setq backup-by-copying t) (setq backup-by-copying t
(setq backup-directory-alist `(("." . ,user-temporary-file-directory) backup-directory-alist `(("." . ,user-temporary-file-directory)
(tramp-file-name-regexp nil))) (tramp-file-name-regexp nil))
(setq auto-save-list-file-prefix (concat user-temporary-file-directory ".auto-saves-")) auto-save-list-file-prefix (concat user-temporary-file-directory ".auto-saves-")
(setq auto-save-file-name-transforms `((".*" ,user-temporary-file-directory t))) auto-save-file-name-transforms `((".*" ,user-temporary-file-directory t)))
;; set default input encoding ;; set default input encoding
(prefer-coding-system 'utf-8-unix) (prefer-coding-system 'utf-8-unix)