From 18da873a8c64aaa21d6587051f4ee5e19b1c1cd3 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Tue, 21 Mar 2023 15:45:11 -0400 Subject: [PATCH] refactor(cli): mkdir and log to doom-state-dir This will be more meaningful in v3, when we start writing profile data to $XDG_{DATA,STATE,CACHE}_HOME instead of $EMACSDIR/.local. --- lisp/doom-cli.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/doom-cli.el b/lisp/doom-cli.el index 568345cdf..d860b63f5 100644 --- a/lisp/doom-cli.el +++ b/lisp/doom-cli.el @@ -20,7 +20,8 @@ (mapc (doom-rpartial #'make-directory 'parents) (list doom-local-dir doom-data-dir - doom-cache-dir)) + doom-cache-dir + doom-state-dir)) ;; HACK: Load `cl' and site files manually to prevent polluting logs and ;; stdout with deprecation and/or file load messages. @@ -229,7 +230,7 @@ If nil, falls back to less.") Only applies if (exit! :pager) or (exit! :pager?) are called.") ;;; Logger settings -(defvar doom-cli-log-file-format (expand-file-name "logs/cli.%s.%s.%s" doom-local-dir) +(defvar doom-cli-log-file-format (expand-file-name "logs/cli.%s.%s.%s" doom-state-dir) "Where to write any output/log file to. Must have two arguments, one for session id and the other for log type.")