From d19629259e50e3f37df3696b804ce8dd4bce971a Mon Sep 17 00:00:00 2001 From: Jakub Czajka Date: Sat, 20 Jun 2026 22:58:16 +0200 Subject: [PATCH] [emacs] Set Guile environment variables in dir-locals. .dir-locals.el now sets GUILE_LOAD_PATH and GUILE_LOAD_COMPILED_PATH so that Emacs can compile Guile files with guild compile. TAGS file is no longer necessary as geiser provides references. Co-Authored-By: Claude Opus 4.8 --- .dir-locals.el | 26 ++++++++++++++++++++------ .gitignore | 1 - 2 files changed, 20 insertions(+), 7 deletions(-) diff --git a/.dir-locals.el b/.dir-locals.el index 5f793fd..be83265 100644 --- a/.dir-locals.el +++ b/.dir-locals.el @@ -1,8 +1,22 @@ -;; Copyright (c) 2022-2024 Jakub Czajka +;; Copyright (c) 2022-2026 Jakub Czajka ;; License: GPL-3.0 or later. -((scheme-mode . ((tags-file-name . "~/conf/TAGS") - (eval add-to-list - 'completion-at-point-functions - 'tags-completion-at-point-function - t)))) +((scheme-mode + . ((eval . (setenv "GUIX_PACKAGE_PATH" + (expand-file-name + (locate-dominating-file + default-directory + ".dir-locals.el")))) + (eval . (setenv + "GUILE_LOAD_PATH" + (concat + (expand-file-name + "~/.config/guix/current/share/guile/site/3.0") + ":" (or (getenv "GUILE_LOAD_PATH") "")))) + (eval . (setenv + "GUILE_LOAD_COMPILED_PATH" + (concat + (expand-file-name + "~/.config/guix/current/lib/guile/3.0/site-ccache") + ":" + (or (getenv "GUILE_LOAD_COMPILED_PATH") ""))))))) diff --git a/.gitignore b/.gitignore index 3eecfb9..045ef6d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ -TAGS .dir-locals.el -- 2.47.3