From 8f3f31bac81b02a4499b8bc752e78f999465bee9 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Tue, 26 Jun 2018 18:07:05 +0200 Subject: [PATCH] Fix hardcoded language-tool path on MacOS Reported by @jwintz --- modules/app/write/config.el | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/modules/app/write/config.el b/modules/app/write/config.el index dc7206216..cda5bc559 100644 --- a/modules/app/write/config.el +++ b/modules/app/write/config.el @@ -29,12 +29,14 @@ :init (setq langtool-default-language "en-US") :config - (unless langtool-language-tool-jar - (setq langtool-language-tool-jar - (cond (IS-MAC - "/usr/local/Cellar/languagetool/4.0/libexec/languagetool-commandline.jar") - (IS-LINUX - "/usr/share/java/languagetool/languagetool-commandline.jar"))))) + (defvar langtool-language-tool-jar + (cond (IS-MAC + (locate-file "libexec/languagetool-commandline.jar" + (doom-files-in "/usr/local/Cellar/languagetool" + :type 'dirs + :depth 1))) + (IS-LINUX + "/usr/share/java/languagetool/languagetool-commandline.jar")))) (def-package! wordnut