diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2021-08-28 15:54:18 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2021-08-31 15:55:26 -0700 |
commit | 1f12dfda4aeb6d08af454d60caa5985b2bd5b1ba (patch) | |
tree | 74ed16275286479a2c9aee411138b41d1d065746 /src/image.lisp | |
parent | a2f6906904352b1ba6309893f9969e22597009d2 (diff) | |
download | consfigurator-1f12dfda4aeb6d08af454d60caa5985b2bd5b1ba.tar.gz |
cache XDG_CACHE_HOME as a connattr
This should provide a performance improvement.
Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src/image.lisp')
-rw-r--r-- | src/image.lisp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/image.lisp b/src/image.lisp index ce3a34a..8bc34b3 100644 --- a/src/image.lisp +++ b/src/image.lisp @@ -142,11 +142,10 @@ already running from FILENAME." (format nil "Dumped image to evaluate ~S" form) "Dumped image to execute current deployment")) (:apply - (let ((file (or filename (ensure-directories-exist - (ensure-pathname - (strcat (or (getenv "XDG_CACHE_HOME") - (strcat (getenv "HOME") "/.cache")) - "/consfigurator/images/latest")))))) + (let ((file (or filename + (ensure-directories-exist + (merge-pathnames "consfigurator/images/latest" + (get-connattr :XDG-CACHE-HOME)))))) (unless (and (not always) (eql :linux (uiop:operating-system)) (pathname-equal file (resolve-symlinks "/proc/self/exe"))) |