diff options
author | Thomas Voss <mail@thomasvoss.com> | 2024-11-27 20:52:46 +0100 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2024-11-27 20:52:46 +0100 |
commit | f8c344ea0e859f04a7bf33264ae237bb51eef7b1 (patch) | |
tree | 15fb0cea942a307fdf467b79f0518fb33fd1d0ff /.config/emacs/early-init.el | |
parent | fef1d8682bf9d88ab52b9d2c8e0ca0b7c7cb6e80 (diff) |
emacs: Make use of xdg.el
Diffstat (limited to '.config/emacs/early-init.el')
-rw-r--r-- | .config/emacs/early-init.el | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/.config/emacs/early-init.el b/.config/emacs/early-init.el index 634acc0..b48d643 100644 --- a/.config/emacs/early-init.el +++ b/.config/emacs/early-init.el @@ -2,25 +2,19 @@ ;;; XDG Base Directory Specification Compliance +(eval-when-compile + (require 'xdg)) + (defconst mm-cache-directory - (expand-file-name - "emacs" - (or (getenv "XDG_CACHE_HOME") - (expand-file-name ".cache" (getenv "HOME")))) + (expand-file-name "emacs" (xdg-cache-home)) "The XDG-conformant cache directory that Emacs should use.") (defconst mm-config-directory - (expand-file-name - "emacs" - (or (getenv "XDG_CONFIG_HOME") - (expand-file-name ".config" (getenv "HOME")))) + (expand-file-name "emacs" (xdg-config-home)) "The XDG-conformant config directory that Emacs should use.") (defconst mm-data-directory - (expand-file-name - "emacs" - (or (getenv "XDG_DATA_HOME") - (expand-file-name ".local/share" (getenv "HOME")))) + (expand-file-name "emacs" (xdg-data-home)) "The XDG-conformant data directory that Emacs should use.") (mapc (lambda (directory) |