Save the theme as soon as you pick it, so new emacs pick it up
This commit is contained in:
parent
d4a756116a
commit
14e4b3d1fe
@ -222,12 +222,17 @@ our case is worse since we have a literate file. Send all custom variables to ~c
|
|||||||
(load custom-file)
|
(load custom-file)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
Save the last used theme when exiting emacs and then reload it.
|
Save the chosen theme after picking a new one
|
||||||
|
|
||||||
#+begin_src emacs-lisp tangle: no
|
#+begin_src emacs-lisp tangle: no
|
||||||
(defun joe/save-current-theme ()
|
(defun joe/save-current-theme (THEME)
|
||||||
(customize-save-variable 'custom-enabled-themes custom-enabled-themes))
|
(let ((inhibit-message t)
|
||||||
(add-hook 'kill-emacs-hook #'joe/save-current-theme)
|
(message-log-max nil))
|
||||||
|
(customize-save-variable 'custom-enabled-themes custom-enabled-themes)))
|
||||||
|
;; (add-hook 'kill-emacs-hook #'joe/save-current-theme)
|
||||||
|
(advice-add 'consult-theme :after #'joe/save-current-theme)
|
||||||
|
(advice-remove 'load-theme 'joe/save-current-theme)
|
||||||
|
|
||||||
#+end_src
|
#+end_src
|
||||||
*** Other
|
*** Other
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user