]> git.eshelyaron.com Git - dotfiles.git/commitdiff
Minor configuration tweaks
authorEshel Yaron <eshel@dazz.io>
Fri, 17 Jun 2022 20:14:29 +0000 (23:14 +0300)
committerEshel Yaron <eshel@dazz.io>
Fri, 17 Jun 2022 20:14:29 +0000 (23:14 +0300)
.emacs.d/esy.org

index 8d27577e1e66979930b8a6c3681bb39ef8022d23..6053b50ed9b93795c54c5a51920a43bfaf9e1c76 100644 (file)
@@ -170,6 +170,10 @@ For further information about Elisp headers, see [[info:elisp#Library
   (setq vertalen--source nil)
   (setq vertalen-history nil)
 
+  (with-eval-after-load 'savehist
+    (add-to-list 'savehist-additional-variables
+                 'vertalen-history))
+
   (defun vertalen (word)
     "Translate WORD."
     (interactive (list (read-string "Translate: " nil 'vertalen-history (thing-at-point 'word))))
@@ -184,7 +188,7 @@ For further information about Elisp headers, see [[info:elisp#Library
 
   (defun vertalen-at-point ()
     "Translate word at point."
-    (interactive)
+    (interactive nil vertalen-mode)
     (vertalen (thing-at-point 'word t)))
 
   (defvar-keymap vertalen-mode-map
@@ -513,9 +517,9 @@ refiling directly into deeper headings as well.
   (defvar esy/org-capture-to-project-heading-history-list nil
     "History list for 'esy/org-capture-to-project-heading'.")
 
-  (require 'savehist)
-  (add-to-list 'savehist-additional-variables
-        'esy/org-capture-to-project-heading-history-list)
+  (with-eval-after-load 'savehist
+   (add-to-list 'savehist-additional-variables
+                'esy/org-capture-to-project-heading-history-list))
 
   (defun esy/org-capture-to-project-heading ()
     "Prompt for a projects and capture a related task."