mirror of
https://github.com/correl/doom-modeline.git
synced 2024-11-27 11:09:52 +00:00
No-op if env executable doesn't exist
This commit is contained in:
parent
72b4ea3741
commit
3d467b7a70
1 changed files with 4 additions and 3 deletions
|
@ -154,9 +154,10 @@ PARSER should be a function for parsing COMMAND's output line-by-line, to
|
||||||
(defalias ',update-fn
|
(defalias ',update-fn
|
||||||
(lambda ()
|
(lambda ()
|
||||||
(when ,enable-var
|
(when ,enable-var
|
||||||
(when-let* ((command (funcall ,command-var)))
|
(when-let* ((command-list (funcall ,command-var))
|
||||||
(setq doom-modeline-env--command (car command)
|
(exe (executable-find (car command-list))))
|
||||||
doom-modeline-env--command-args (cdr command)
|
(setq doom-modeline-env--command exe
|
||||||
|
doom-modeline-env--command-args (cdr command-list)
|
||||||
doom-modeline-env--parser ,parser-var)
|
doom-modeline-env--parser ,parser-var)
|
||||||
(doom-modeline-update-env))))
|
(doom-modeline-update-env))))
|
||||||
(format "Updates the %s version string in the modeline." ',name))
|
(format "Updates the %s version string in the modeline." ',name))
|
||||||
|
|
Loading…
Reference in a new issue