diff --git a/emacs/init.org b/emacs/init.org index 1037fc2..1580cf2 100755 --- a/emacs/init.org +++ b/emacs/init.org @@ -1835,20 +1835,19 @@ Add a w3m filter to handle the code block delimiters: It needs a helper script to work properly. #+BEGIN_SRC emacs-lisp - (defvar wakatime-path + (setq wakatime-path (if (file-exists-p "/usr/local/bin/wakatime") - "/usr/local/bin/wakatime" + "/usr/local/bin/wakatime" (when (file-exists-p "/usr/bin/wakatime") - "/usr/bin/wakatime"))) + "/usr/bin/wakatime"))) - (when wakatime-path - (let ((wakatime-key (password-store-get "wakatime-api-key"))) - (use-package wakatime-mode - :init - (setq wakatime-api-key wakatime-key - wakatime-cli-path wakatime-path) - :config - (global-wakatime-mode)))) + (use-package wakatime-mode + :if wakatime-path + :init + (setq wakatime-api-key (password-store-get "wakatime-api-key") + wakatime-cli-path wakatime-path) + :config + (global-wakatime-mode)) #+END_SRC * Elfeed