Desktop: Comment out obsolete code.
parent
80ffff63cf
commit
e8e6d7f0cd
|
@ -234,23 +234,21 @@
|
|||
;;; REVIEW: `desktop-kill' should not query the user in `kill-emacs-hook'.
|
||||
;;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=28943
|
||||
(defun ambrevar/desktop-setup (&rest _ignored)
|
||||
(when (and (fboundp 'server-running-p)
|
||||
(server-running-p)
|
||||
(or (not (boundp 'desktop-save-mode))
|
||||
(null desktop-save-mode)))
|
||||
(when (< emacs-major-version 27)
|
||||
;; TODO: By default, Emacs<27 prompts for unsafe variable when loading desktop
|
||||
;; which stucks the daemon. Disable this behaviour.
|
||||
(defun ambrevar/enable-safe-local-variables ()
|
||||
(setq enable-local-variables t))
|
||||
(add-hook 'after-init-hook 'ambrevar/enable-safe-local-variables))
|
||||
(require 'desktop) ; This adds a hook to `after-init-hook'.
|
||||
(when (< emacs-major-version 27)
|
||||
(defun ambrevar/enable-all-local-variables ()
|
||||
(setq enable-local-variables :all))
|
||||
(add-hook 'after-init-hook 'ambrevar/enable-all-local-variables))
|
||||
(when (< emacs-major-version 27)
|
||||
(load "patch-desktop"))
|
||||
(when (or (not (boundp 'desktop-save-mode))
|
||||
(null desktop-save-mode))
|
||||
;; (when (< emacs-major-version 27)
|
||||
;; ;; TODO: By default, Emacs<27 prompts for unsafe variable when loading desktop
|
||||
;; ;; which stucks the daemon. Disable this behaviour.
|
||||
;; (defun ambrevar/enable-safe-local-variables ()
|
||||
;; (setq enable-local-variables t))
|
||||
;; (add-hook 'after-init-hook 'ambrevar/enable-safe-local-variables))
|
||||
(require 'desktop) ; This adds a hook to `after-init-hook'.
|
||||
;; (when (< emacs-major-version 27)
|
||||
;; (defun ambrevar/enable-all-local-variables ()
|
||||
;; (setq enable-local-variables :all))
|
||||
;; (add-hook 'after-init-hook 'ambrevar/enable-all-local-variables))
|
||||
;; (when (< emacs-major-version 27)
|
||||
;; (load "patch-desktop"))
|
||||
(setq history-length 250
|
||||
;; Default timer (30) is way too high: for somebody too frenzy, the timer
|
||||
;; might never be saved. See
|
||||
|
|
Loading…
Reference in New Issue