GNU bug report logs -
#65575
guix-emacs-autoload-packages does not autoreload newly installed packages
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 65575 in the body.
You can then email your comments to 65575 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 04:51:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-guix <at> gnu.org
.
(Mon, 28 Aug 2023 04:51:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hi,
Since some time, our guix-emacs-autoload-packages in Emacs stopped being
useful at refreshing newly installed packages.
I'll send a proposed change to address this.
--
Thanks,
Maxim
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 05:08:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el: Declare LEXCICAL-BINDING file
variable to true.
---
gnu/packages/aux-files/emacs/guix-emacs.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 708093267d..c98e7fe369 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -1,3 +1,4 @@
+;;; -*- lexical-binding: t; -*-
;;; guix-emacs.el --- Emacs packages installed with Guix
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
base-commit: 0aa74bebe31907c4abc71468319b220f908edd90
prerequisite-patch-id: 592cc2d7ba9ac74a0c6bcd140e1ced345f614a1b
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 05:13:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el: Declare LEXCICAL-BINDING file
variable to true.
---
gnu/packages/aux-files/emacs/guix-emacs.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 708093267d..c98e7fe369 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -1,3 +1,4 @@
+;;; -*- lexical-binding: t; -*-
;;; guix-emacs.el --- Emacs packages installed with Guix
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
base-commit: 0aa74bebe31907c4abc71468319b220f908edd90
prerequisite-patch-id: 319f4581076b0c137330d5d59e6436ab9f1cdafb
prerequisite-patch-id: 592cc2d7ba9ac74a0c6bcd140e1ced345f614a1b
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 05:13:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el
(guix-emacs--subdirs-files): New procedure.
(guix-emacs-load-package-descriptors): Use it.
---
gnu/packages/aux-files/emacs/guix-emacs.el | 33 +++++++++++++---------
1 file changed, 19 insertions(+), 14 deletions(-)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index c98e7fe369..ed0c913163 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -3,7 +3,7 @@
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
;; Copyright © 2017 Kyle Meyer <kyle <at> kyleam.com>
-;; Copyright © 2019 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
+;; Copyright © 2019, 2023 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
;; This file is part of GNU Guix.
@@ -47,6 +47,13 @@ The files in the list do not have extensions (.el, .elc)."
(string-match-p "/share/emacs/site-lisp" dir))
load-path))
+(defun guix-emacs--subdirs-files ()
+ "Return the Guix subdirs.el files found on the (non-core) load path."
+ (seq-filter #'file-exists-p
+ (mapcar (lambda (dir)
+ (expand-file-name "subdirs.el" dir))
+ (guix-emacs--non-core-load-path))))
+
;;;###autoload
(defun guix-emacs-autoload-packages ()
"Autoload Emacs packages found in EMACSLOADPATH.
@@ -63,19 +70,17 @@ The files in the list do not have extensions (.el, .elc)."
;;;###autoload
(defun guix-emacs-load-package-descriptors ()
"Load descriptors for packages found in EMACSLOADPATH via subdirs.el."
- (dolist (dir (guix-emacs--non-core-load-path))
- (let ((subdirs-file (expand-file-name "subdirs.el" dir)))
- (when (file-exists-p subdirs-file)
- (with-temp-buffer
- (insert-file-contents subdirs-file)
- (goto-char (point-min))
- (let ((subdirs (read (current-buffer))))
- (and (equal (car-safe subdirs) 'normal-top-level-add-to-load-path)
- (equal (car-safe (cadr subdirs)) 'list)
- (dolist (subdir (cdadr subdirs))
- (let ((pkg-dir (expand-file-name subdir dir)))
- (when (file-directory-p pkg-dir)
- (package-load-descriptor pkg-dir)))))))))))
+ (dolist (subdirs-file (guix-emacs--subdirs-files))
+ (with-temp-buffer
+ (insert-file-contents subdirs-file)
+ (goto-char (point-min))
+ (let ((subdirs (read (current-buffer))))
+ (and (equal (car-safe subdirs) 'normal-top-level-add-to-load-path)
+ (equal (car-safe (cadr subdirs)) 'list)
+ (dolist (subdir (cdadr subdirs))
+ (let ((pkg-dir (expand-file-name subdir dir)))
+ (when (file-directory-p pkg-dir)
+ (package-load-descriptor pkg-dir)))))))))
;; If emacs built with tree-sitter, read the value of the environment variable
;; to make tree-sitter grammars available in emacs out-of-the-box.
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 05:13:03 GMT)
Full text and
rfc822 format available.
Message #17 received at 65575 <at> debbugs.gnu.org (full text, mbox):
This fixes a regression introduced with 79cfe30f3 ("build-system: emacs: Use
subdirectories again.") which caused the 'guix-emacs-autoload-packages' to no
longer be able to autoload all packages.
* gnu/packages/aux-files/emacs/guix-emacs.el
(guix-emacs-autoload-packages-called): New variable.
(guix-emacs-autoload-packages): Reload subdirs.el files an all but the first
call of this procedure.
* doc/guix.texi (Application Setup): Document that
'guix-emacs-autoload-packages' can be invoked interactively to auto-reload
newly installed Emacs packages.
---
doc/guix.texi | 11 +++++++----
gnu/packages/aux-files/emacs/guix-emacs.el | 12 ++++++++++++
2 files changed, 19 insertions(+), 4 deletions(-)
diff --git a/doc/guix.texi b/doc/guix.texi
index f82bb99069..66da4f9cd4 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -2167,12 +2167,15 @@ Application Setup
Emacs through the @env{EMACSLOADPATH} environment variable, which is
set when installing Emacs itself.
+@cindex guix-emacs-autoload-packages, refreshing Emacs packages
Additionally, autoload definitions are automatically evaluated at the
initialization of Emacs, by the Guix-specific
-@code{guix-emacs-autoload-packages} procedure. If, for some reason, you
-want to avoid auto-loading the Emacs packages installed with Guix, you
-can do so by running Emacs with the @option{--no-site-file} option
-(@pxref{Init File,,, emacs, The GNU Emacs Manual}).
+@code{guix-emacs-autoload-packages} procedure. This procedure can be
+interactively invoked to have newly installed Emacs packages discovered,
+without having to restart Emacs. If, for some reason, you want to avoid
+auto-loading the Emacs packages installed with Guix, you can do so by
+running Emacs with the @option{--no-site-file} option (@pxref{Init
+File,,, emacs, The GNU Emacs Manual}).
@quotation Note
Emacs can now compile packages natively. Under the default
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index ed0c913163..b4a4fd1d91 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -54,6 +54,9 @@ The files in the list do not have extensions (.el, .elc)."
(expand-file-name "subdirs.el" dir))
(guix-emacs--non-core-load-path))))
+(defvar guix-emacs-autoload-packages-called nil
+ "True if `guix-emacs-autoload-packages' was already run.")
+
;;;###autoload
(defun guix-emacs-autoload-packages ()
"Autoload Emacs packages found in EMACSLOADPATH.
@@ -61,6 +64,15 @@ The files in the list do not have extensions (.el, .elc)."
'Autoload' means to load the 'autoloads' files matching
`guix-emacs-autoloads-regexp'."
(interactive)
+ ;; Reload the subdirs.el files such as the one generated by the Guix profile
+ ;; hook, so that newly installed Emacs packages located under
+ ;; sub-directories are put on the load-path without having to restart Emacs.
+ (if guix-emacs-autoload-packages-called
+ (progn
+ (mapc #'load-file (guix-emacs--subdirs-files))
+ (setq load-path (delete-dups load-path)))
+ (setq guix-emacs-autoload-packages-called t))
+
(let ((autoloads (mapcan #'guix-emacs-find-autoloads
(guix-emacs--non-core-load-path))))
(mapc (lambda (f)
--
2.41.0
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 06:18:02 GMT)
Full text and
rfc822 format available.
Message #20 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Hi Maxim,
Am Montag, dem 28.08.2023 um 01:11 -0400 schrieb Maxim Cournoyer:
> This fixes a regression introduced with 79cfe30f3 ("build-system:
> emacs: Use subdirectories again.") which caused the
> 'guix-emacs-autoload-packages' to no
> longer be able to autoload all packages.
>
> * gnu/packages/aux-files/emacs/guix-emacs.el
> (guix-emacs-autoload-packages-called): New variable.
> (guix-emacs-autoload-packages): Reload subdirs.el files an all but
> the first call of this procedure.
> * doc/guix.texi (Application Setup): Document that
> 'guix-emacs-autoload-packages' can be invoked interactively to auto-
> reload newly installed Emacs packages.
>
> ---
Thank you for looking at this. I agree that even if we don't want to
generally load new packages into existing Emacs processes for the
breakages they might induce, not being able to do so at all is also not
a great option. However, I don't think that tracking is the right
solution here, see below.
> doc/guix.texi | 11 +++++++----
> gnu/packages/aux-files/emacs/guix-emacs.el | 12 ++++++++++++
> 2 files changed, 19 insertions(+), 4 deletions(-)
>
> diff --git a/doc/guix.texi b/doc/guix.texi
> index f82bb99069..66da4f9cd4 100644
> --- a/doc/guix.texi
> +++ b/doc/guix.texi
> @@ -2167,12 +2167,15 @@ Application Setup
> Emacs through the @env{EMACSLOADPATH} environment variable, which is
> set when installing Emacs itself.
>
> +@cindex guix-emacs-autoload-packages, refreshing Emacs packages
> Additionally, autoload definitions are automatically evaluated at
> the
> initialization of Emacs, by the Guix-specific
> -@code{guix-emacs-autoload-packages} procedure. If, for some reason,
> you
> -want to avoid auto-loading the Emacs packages installed with Guix,
> you
> -can do so by running Emacs with the @option{--no-site-file} option
> -(@pxref{Init File,,, emacs, The GNU Emacs Manual}).
> +@code{guix-emacs-autoload-packages} procedure. This procedure can
> be
> +interactively invoked to have newly installed Emacs packages
> discovered,
> +without having to restart Emacs. If, for some reason, you want to
> avoid
> +auto-loading the Emacs packages installed with Guix, you can do so
> by
> +running Emacs with the @option{--no-site-file} option (@pxref{Init
> +File,,, emacs, The GNU Emacs Manual}).
>
> @quotation Note
> Emacs can now compile packages natively. Under the default
> diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el
> b/gnu/packages/aux-files/emacs/guix-emacs.el
> index ed0c913163..b4a4fd1d91 100644
> --- a/gnu/packages/aux-files/emacs/guix-emacs.el
> +++ b/gnu/packages/aux-files/emacs/guix-emacs.el
> @@ -54,6 +54,9 @@ The files in the list do not have extensions (.el,
> .elc)."
> (expand-file-name "subdirs.el" dir))
> (guix-emacs--non-core-load-path))))
>
> +(defvar guix-emacs-autoload-packages-called nil
> + "True if `guix-emacs-autoload-packages' was already run.")
> +
> ;;;###autoload
> (defun guix-emacs-autoload-packages ()
> "Autoload Emacs packages found in EMACSLOADPATH.
> @@ -61,6 +64,15 @@ The files in the list do not have extensions (.el,
> .elc)."
> 'Autoload' means to load the 'autoloads' files matching
> `guix-emacs-autoloads-regexp'."
> (interactive)
> + ;; Reload the subdirs.el files such as the one generated by the
> Guix profile
> + ;; hook, so that newly installed Emacs packages located under
> + ;; sub-directories are put on the load-path without having to
> restart Emacs.
> + (if guix-emacs-autoload-packages-called
> + (progn
> + (mapc #'load-file (guix-emacs--subdirs-files))
> + (setq load-path (delete-dups load-path)))
> + (setq guix-emacs-autoload-packages-called t))
> +
Rather than keeping track of whether the function was already called
(which would make debugging more tedious if you also have e.g. broken
packages from another source on your EMACSLOADPATH), I think the user
ought to signal their intent to reload the subdirs files via the
universal argument.
e.g.
(defun guix-emacs-autoload-packages (&optional reload)
"..."
(interactive "P")
(when reload (mapc #'load-file (guix-emacs--subdirs-files)))
...)
WDYT?
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 15:19:02 GMT)
Full text and
rfc822 format available.
Message #23 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el: Declare LEXCICAL-BINDING file
variable to true.
---
(no changes since v1)
gnu/packages/aux-files/emacs/guix-emacs.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 708093267d..c98e7fe369 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -1,3 +1,4 @@
+;;; -*- lexical-binding: t; -*-
;;; guix-emacs.el --- Emacs packages installed with Guix
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
base-commit: 0aa74bebe31907c4abc71468319b220f908edd90
prerequisite-patch-id: 319f4581076b0c137330d5d59e6436ab9f1cdafb
prerequisite-patch-id: 592cc2d7ba9ac74a0c6bcd140e1ced345f614a1b
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 15:19:02 GMT)
Full text and
rfc822 format available.
Message #26 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el
(guix-emacs--subdirs-files): New procedure.
(guix-emacs-load-package-descriptors): Use it.
---
Changes in v2:
- Fix unbound 'dir' variable
gnu/packages/aux-files/emacs/guix-emacs.el | 34 +++++++++++++---------
1 file changed, 20 insertions(+), 14 deletions(-)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index c98e7fe369..4db7ec28c9 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -3,7 +3,7 @@
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
;; Copyright © 2017 Kyle Meyer <kyle <at> kyleam.com>
-;; Copyright © 2019 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
+;; Copyright © 2019, 2023 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
;; This file is part of GNU Guix.
@@ -47,6 +47,13 @@ The files in the list do not have extensions (.el, .elc)."
(string-match-p "/share/emacs/site-lisp" dir))
load-path))
+(defun guix-emacs--subdirs-files ()
+ "Return the Guix subdirs.el files found on the (non-core) load path."
+ (seq-filter #'file-exists-p
+ (mapcar (lambda (dir)
+ (expand-file-name "subdirs.el" dir))
+ (guix-emacs--non-core-load-path))))
+
;;;###autoload
(defun guix-emacs-autoload-packages ()
"Autoload Emacs packages found in EMACSLOADPATH.
@@ -63,19 +70,18 @@ The files in the list do not have extensions (.el, .elc)."
;;;###autoload
(defun guix-emacs-load-package-descriptors ()
"Load descriptors for packages found in EMACSLOADPATH via subdirs.el."
- (dolist (dir (guix-emacs--non-core-load-path))
- (let ((subdirs-file (expand-file-name "subdirs.el" dir)))
- (when (file-exists-p subdirs-file)
- (with-temp-buffer
- (insert-file-contents subdirs-file)
- (goto-char (point-min))
- (let ((subdirs (read (current-buffer))))
- (and (equal (car-safe subdirs) 'normal-top-level-add-to-load-path)
- (equal (car-safe (cadr subdirs)) 'list)
- (dolist (subdir (cdadr subdirs))
- (let ((pkg-dir (expand-file-name subdir dir)))
- (when (file-directory-p pkg-dir)
- (package-load-descriptor pkg-dir)))))))))))
+ (dolist (subdirs-file (guix-emacs--subdirs-files))
+ (with-temp-buffer
+ (insert-file-contents subdirs-file)
+ (goto-char (point-min))
+ (let ((subdirs (read (current-buffer))))
+ (and (equal (car-safe subdirs) 'normal-top-level-add-to-load-path)
+ (equal (car-safe (cadr subdirs)) 'list)
+ (dolist (subdir (cdadr subdirs))
+ (let ((pkg-dir (expand-file-name
+ subdir (file-name-directory subdirs-file))))
+ (when (file-directory-p pkg-dir)
+ (package-load-descriptor pkg-dir)))))))))
;; If emacs built with tree-sitter, read the value of the environment variable
;; to make tree-sitter grammars available in emacs out-of-the-box.
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 15:19:03 GMT)
Full text and
rfc822 format available.
Message #29 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el: Expound commentary.
(guix-emacs-verbose): New variable.
(guix-emacs--load-file-no-error): New procedure.
(guix-emacs-autoload-packages): Use it.
---
Changes in v2:
- New commit
gnu/packages/aux-files/emacs/guix-emacs.el | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 4db7ec28c9..84284dde39 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -22,8 +22,9 @@
;;; Commentary:
-;; This file provides auxiliary code to autoload Emacs packages
-;; installed with Guix.
+;; This file provides auxiliary code to autoload Emacs packages installed with
+;; Guix. To produce verbose messages useful while debugging, set the
+;; GUIX-EMACS-VERBOSE variable to true.
;;; Code:
(require 'seq)
@@ -41,6 +42,15 @@ The files in the list do not have extensions (.el, .elc)."
(directory-files directory 'full-name
guix-emacs-autoloads-regexp))))
+(defcustom guix-emacs-verbose nil
+ "Set to true to provide verbose messages, such as when loading packages."
+ :type 'boolean
+ :group 'guix-emacs)
+
+(defun guix-emacs--load-file-no-error (file)
+ "Load FILE, ignoring any errors"
+ (load file 'noerror (not guix-emacs-verbose)))
+
(defun guix-emacs--non-core-load-path ()
;; Filter out core Elisp directories, which are already handled by Emacs.
(seq-filter (lambda (dir)
@@ -63,9 +73,7 @@ The files in the list do not have extensions (.el, .elc)."
(interactive)
(let ((autoloads (mapcan #'guix-emacs-find-autoloads
(guix-emacs--non-core-load-path))))
- (mapc (lambda (f)
- (load f 'noerror t))
- autoloads)))
+ (mapc #'guix-emacs--load-file-no-error autoloads)))
;;;###autoload
(defun guix-emacs-load-package-descriptors ()
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 15:19:03 GMT)
Full text and
rfc822 format available.
Message #32 received at 65575 <at> debbugs.gnu.org (full text, mbox):
This fixes a regression introduced with 79cfe30f3 ("build-system: emacs: Use
subdirectories again.") which caused the 'guix-emacs-autoload-packages' to no
longer be able to autoload all packages.
* gnu/packages/aux-files/emacs/guix-emacs.el
(guix-emacs-autoload-packages-called): New variable.
(guix-emacs-autoload-packages): Reload subdirs.el files on all but the first
call of this procedure, or when a prefix argument is provided. Update doc.
* doc/guix.texi (Application Setup): Document that
'guix-emacs-autoload-packages' can be invoked interactively to auto-reload
newly installed Emacs packages.
---
Changes in v2:
- Safely load subdirs.el files
- Add 'reload' prefix argument as override for guix-emacs-autoload-packages
doc/guix.texi | 11 +++++++----
gnu/packages/aux-files/emacs/guix-emacs.el | 21 ++++++++++++++++++---
2 files changed, 25 insertions(+), 7 deletions(-)
diff --git a/doc/guix.texi b/doc/guix.texi
index f82bb99069..66da4f9cd4 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -2167,12 +2167,15 @@ Application Setup
Emacs through the @env{EMACSLOADPATH} environment variable, which is
set when installing Emacs itself.
+@cindex guix-emacs-autoload-packages, refreshing Emacs packages
Additionally, autoload definitions are automatically evaluated at the
initialization of Emacs, by the Guix-specific
-@code{guix-emacs-autoload-packages} procedure. If, for some reason, you
-want to avoid auto-loading the Emacs packages installed with Guix, you
-can do so by running Emacs with the @option{--no-site-file} option
-(@pxref{Init File,,, emacs, The GNU Emacs Manual}).
+@code{guix-emacs-autoload-packages} procedure. This procedure can be
+interactively invoked to have newly installed Emacs packages discovered,
+without having to restart Emacs. If, for some reason, you want to avoid
+auto-loading the Emacs packages installed with Guix, you can do so by
+running Emacs with the @option{--no-site-file} option (@pxref{Init
+File,,, emacs, The GNU Emacs Manual}).
@quotation Note
Emacs can now compile packages natively. Under the default
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 84284dde39..aeb85f8487 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -64,13 +64,28 @@ The files in the list do not have extensions (.el, .elc)."
(expand-file-name "subdirs.el" dir))
(guix-emacs--non-core-load-path))))
+(defvar guix-emacs-autoload-packages-called nil
+ "True if `guix-emacs-autoload-packages' was already run.")
+
;;;###autoload
-(defun guix-emacs-autoload-packages ()
+(defun guix-emacs-autoload-packages (&optional reload)
"Autoload Emacs packages found in EMACSLOADPATH.
'Autoload' means to load the 'autoloads' files matching
-`guix-emacs-autoloads-regexp'."
- (interactive)
+`guix-emacs-autoloads-regexp'. When the optional RELOAD prefix
+argument is true, reload the subdirs.el files found on the load
+path; this behavior is active by default unless you've started
+Emacs with the '--no-site-file' option."
+ (interactive "P")
+ ;; Reload the subdirs.el files such as the one generated by the Guix profile
+ ;; hook, so that newly installed Emacs packages located under
+ ;; sub-directories are put on the load-path without having to restart Emacs.
+ (if (or reload guix-emacs-autoload-packages-called)
+ (progn
+ (mapc #'guix-emacs--load-file-no-error (guix-emacs--subdirs-files))
+ (setq load-path (delete-dups load-path)))
+ (setq guix-emacs-autoload-packages-called t))
+
(let ((autoloads (mapcan #'guix-emacs-find-autoloads
(guix-emacs--non-core-load-path))))
(mapc #'guix-emacs--load-file-no-error autoloads)))
--
2.41.0
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 15:22:02 GMT)
Full text and
rfc822 format available.
Message #35 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Hi Liliana,
Liliana Marie Prikler <liliana.prikler <at> ist.tugraz.at> writes:
> Hi Maxim,
>
> Am Montag, dem 28.08.2023 um 01:11 -0400 schrieb Maxim Cournoyer:
>> This fixes a regression introduced with 79cfe30f3 ("build-system:
>> emacs: Use subdirectories again.") which caused the
>> 'guix-emacs-autoload-packages' to no
>> longer be able to autoload all packages.
>>
>> * gnu/packages/aux-files/emacs/guix-emacs.el
>> (guix-emacs-autoload-packages-called): New variable.
>> (guix-emacs-autoload-packages): Reload subdirs.el files an all but
>> the first call of this procedure.
>> * doc/guix.texi (Application Setup): Document that
>> 'guix-emacs-autoload-packages' can be invoked interactively to auto-
>> reload newly installed Emacs packages.
>>
>> ---
> Thank you for looking at this. I agree that even if we don't want to
> generally load new packages into existing Emacs processes for the
> breakages they might induce, not being able to do so at all is also not
> a great option. However, I don't think that tracking is the right
> solution here, see below.
[...]
>> diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el
>> b/gnu/packages/aux-files/emacs/guix-emacs.el
>> index ed0c913163..b4a4fd1d91 100644
>> --- a/gnu/packages/aux-files/emacs/guix-emacs.el
>> +++ b/gnu/packages/aux-files/emacs/guix-emacs.el
>> @@ -54,6 +54,9 @@ The files in the list do not have extensions (.el,
>> .elc)."
>> (expand-file-name "subdirs.el" dir))
>> (guix-emacs--non-core-load-path))))
>>
>> +(defvar guix-emacs-autoload-packages-called nil
>> + "True if `guix-emacs-autoload-packages' was already run.")
>> +
>> ;;;###autoload
>> (defun guix-emacs-autoload-packages ()
>> "Autoload Emacs packages found in EMACSLOADPATH.
>> @@ -61,6 +64,15 @@ The files in the list do not have extensions (.el,
>> .elc)."
>> 'Autoload' means to load the 'autoloads' files matching
>> `guix-emacs-autoloads-regexp'."
>> (interactive)
>> + ;; Reload the subdirs.el files such as the one generated by the
>> Guix profile
>> + ;; hook, so that newly installed Emacs packages located under
>> + ;; sub-directories are put on the load-path without having to
>> restart Emacs.
>> + (if guix-emacs-autoload-packages-called
>> + (progn
>> + (mapc #'load-file (guix-emacs--subdirs-files))
>> + (setq load-path (delete-dups load-path)))
>> + (setq guix-emacs-autoload-packages-called t))
>> +
> Rather than keeping track of whether the function was already called
> (which would make debugging more tedious if you also have e.g. broken
> packages from another source on your EMACSLOADPATH), I think the user
> ought to signal their intent to reload the subdirs files via the
> universal argument.
>
> e.g.
> (defun guix-emacs-autoload-packages (&optional reload)
> "..."
> (interactive "P")
> (when reload (mapc #'load-file (guix-emacs--subdirs-files)))
> ...)
>
> WDYT?
The reason for avoiding loading the subdirs.el files on the first call
is just an optimization, since it would at this time duplicate work
already done by Emacs itself when it first executes. This shouldn't
fail; I've now employed the same 'noerror strategy as used for autoloads
to ensure that.
There's one edge case I've just thought though, which is if a user
invoked emacs with the documented '--no-site-file' option disabling
loading autoloads; this would cause guix-emacs-autoload-packages-called
to be nil.
To balance between making things both convenient and flexible, I've
preserved the tracking but also added the reload override you suggested.
Let me know what you think.
Thank you for the review!
--
Thanks,
Maxim
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Mon, 28 Aug 2023 16:56:01 GMT)
Full text and
rfc822 format available.
Message #38 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Am Montag, dem 28.08.2023 um 11:16 -0400 schrieb Maxim Cournoyer:
> This fixes a regression introduced with 79cfe30f3 ("build-system:
> emacs: Use subdirectories again.") which caused the
> 'guix-emacs-autoload-packages' to no longer be able to autoload all
> packages.
>
> * gnu/packages/aux-files/emacs/guix-emacs.el
> (guix-emacs-autoload-packages-called): New variable.
> (guix-emacs-autoload-packages): Reload subdirs.el files on all but
> the first call of this procedure, or when a prefix argument is
> provided.
What's the reason to still keep the variable? Even if we call load-
file with 'noerror, the way in which it is set is quite weird and imho,
it would keep things simpler if we had the clear semantics of
universal-argument → reload
no universal-argument → no reload
or the other way round.
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Tue, 29 Aug 2023 20:09:02 GMT)
Full text and
rfc822 format available.
Message #41 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Am Montag, dem 28.08.2023 um 11:20 -0400 schrieb Maxim Cournoyer:
> > e.g.
> > (defun guix-emacs-autoload-packages (&optional reload)
> > "..."
> > (interactive "P")
> > (when reload (mapc #'load-file (guix-emacs--subdirs-files)))
> > ...)
> >
> > WDYT?
>
> The reason for avoiding loading the subdirs.el files on the first
> call is just an optimization, since it would at this time duplicate
> work already done by Emacs itself when it first executes. This
> shouldn't fail; I've now employed the same 'noerror strategy as used
> for autoloads to ensure that.
>
> There's one edge case I've just thought though, which is if a user
> invoked emacs with the documented '--no-site-file' option disabling
> loading autoloads; this would cause guix-emacs-autoload-packages-
> called to be nil.
>
> To balance between making things both convenient and flexible, I've
> preserved the tracking but also added the reload override you
> suggested. Let me know what you think.
Assuming convenience equates to not needing to type C-u, we can also
achieve that without tracking:
(defun guix-emacs-autoload-packages (&optional noexpand)
"Autoload Emacs packages found in EMACSLOADPATH.
'Autoload' means to load the 'autoloads' files matching
`guix-emacs-autoloads-regexp'. Before doing so, expand load-path by
loading subdirs.el files found in it, unless NOEXPAND is given."
(interactive "P")
(unless noexpand (mapc #'load-file (guix-emacs--subdirs-files)))
...)
In our own init code, we should simply call it as
(guix-emacs-autoload-packages 'noexpand)
then, since this expansion is already done earlier by Emacs.
Cheers
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Fri, 01 Sep 2023 04:55:01 GMT)
Full text and
rfc822 format available.
Message #44 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el: Declare LEXCICAL-BINDING file
variable to true.
---
(no changes since v1)
gnu/packages/aux-files/emacs/guix-emacs.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 708093267d..c98e7fe369 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -1,3 +1,4 @@
+;;; -*- lexical-binding: t; -*-
;;; guix-emacs.el --- Emacs packages installed with Guix
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
base-commit: f66fa5f917e76935187935b09ae7ac037b8b35f8
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Fri, 01 Sep 2023 04:55:02 GMT)
Full text and
rfc822 format available.
Message #47 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el
(guix-emacs--subdirs-files): New procedure.
(guix-emacs-load-package-descriptors): Use it.
---
(no changes since v2)
Changes in v2:
- Fix unbound 'dir' variable
gnu/packages/aux-files/emacs/guix-emacs.el | 34 +++++++++++++---------
1 file changed, 20 insertions(+), 14 deletions(-)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index c98e7fe369..4db7ec28c9 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -3,7 +3,7 @@
;; Copyright © 2014, 2015, 2016, 2017 Alex Kost <alezost <at> gmail.com>
;; Copyright © 2017 Kyle Meyer <kyle <at> kyleam.com>
-;; Copyright © 2019 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
+;; Copyright © 2019, 2023 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
;; This file is part of GNU Guix.
@@ -47,6 +47,13 @@ The files in the list do not have extensions (.el, .elc)."
(string-match-p "/share/emacs/site-lisp" dir))
load-path))
+(defun guix-emacs--subdirs-files ()
+ "Return the Guix subdirs.el files found on the (non-core) load path."
+ (seq-filter #'file-exists-p
+ (mapcar (lambda (dir)
+ (expand-file-name "subdirs.el" dir))
+ (guix-emacs--non-core-load-path))))
+
;;;###autoload
(defun guix-emacs-autoload-packages ()
"Autoload Emacs packages found in EMACSLOADPATH.
@@ -63,19 +70,18 @@ The files in the list do not have extensions (.el, .elc)."
;;;###autoload
(defun guix-emacs-load-package-descriptors ()
"Load descriptors for packages found in EMACSLOADPATH via subdirs.el."
- (dolist (dir (guix-emacs--non-core-load-path))
- (let ((subdirs-file (expand-file-name "subdirs.el" dir)))
- (when (file-exists-p subdirs-file)
- (with-temp-buffer
- (insert-file-contents subdirs-file)
- (goto-char (point-min))
- (let ((subdirs (read (current-buffer))))
- (and (equal (car-safe subdirs) 'normal-top-level-add-to-load-path)
- (equal (car-safe (cadr subdirs)) 'list)
- (dolist (subdir (cdadr subdirs))
- (let ((pkg-dir (expand-file-name subdir dir)))
- (when (file-directory-p pkg-dir)
- (package-load-descriptor pkg-dir)))))))))))
+ (dolist (subdirs-file (guix-emacs--subdirs-files))
+ (with-temp-buffer
+ (insert-file-contents subdirs-file)
+ (goto-char (point-min))
+ (let ((subdirs (read (current-buffer))))
+ (and (equal (car-safe subdirs) 'normal-top-level-add-to-load-path)
+ (equal (car-safe (cadr subdirs)) 'list)
+ (dolist (subdir (cdadr subdirs))
+ (let ((pkg-dir (expand-file-name
+ subdir (file-name-directory subdirs-file))))
+ (when (file-directory-p pkg-dir)
+ (package-load-descriptor pkg-dir)))))))))
;; If emacs built with tree-sitter, read the value of the environment variable
;; to make tree-sitter grammars available in emacs out-of-the-box.
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Fri, 01 Sep 2023 04:55:02 GMT)
Full text and
rfc822 format available.
Message #50 received at 65575 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/aux-files/emacs/guix-emacs.el: Expound commentary.
(guix-emacs-verbose): New variable.
(guix-emacs--load-file-no-error): New procedure.
(guix-emacs-autoload-packages): Use it.
---
(no changes since v2)
Changes in v2:
- New commit
gnu/packages/aux-files/emacs/guix-emacs.el | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 4db7ec28c9..84284dde39 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -22,8 +22,9 @@
;;; Commentary:
-;; This file provides auxiliary code to autoload Emacs packages
-;; installed with Guix.
+;; This file provides auxiliary code to autoload Emacs packages installed with
+;; Guix. To produce verbose messages useful while debugging, set the
+;; GUIX-EMACS-VERBOSE variable to true.
;;; Code:
(require 'seq)
@@ -41,6 +42,15 @@ The files in the list do not have extensions (.el, .elc)."
(directory-files directory 'full-name
guix-emacs-autoloads-regexp))))
+(defcustom guix-emacs-verbose nil
+ "Set to true to provide verbose messages, such as when loading packages."
+ :type 'boolean
+ :group 'guix-emacs)
+
+(defun guix-emacs--load-file-no-error (file)
+ "Load FILE, ignoring any errors"
+ (load file 'noerror (not guix-emacs-verbose)))
+
(defun guix-emacs--non-core-load-path ()
;; Filter out core Elisp directories, which are already handled by Emacs.
(seq-filter (lambda (dir)
@@ -63,9 +73,7 @@ The files in the list do not have extensions (.el, .elc)."
(interactive)
(let ((autoloads (mapcan #'guix-emacs-find-autoloads
(guix-emacs--non-core-load-path))))
- (mapc (lambda (f)
- (load f 'noerror t))
- autoloads)))
+ (mapc #'guix-emacs--load-file-no-error autoloads)))
;;;###autoload
(defun guix-emacs-load-package-descriptors ()
--
2.41.0
Information forwarded
to
andrew <at> trop.in, cox.katherine.e+guix <at> gmail.com, liliana.prikler <at> gmail.com, bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Fri, 01 Sep 2023 04:55:03 GMT)
Full text and
rfc822 format available.
Message #53 received at 65575 <at> debbugs.gnu.org (full text, mbox):
This fixes a regression introduced with 79cfe30f3 ("build-system: emacs: Use
subdirectories again.") which caused the 'guix-emacs-autoload-packages' to no
longer be able to autoload all packages.
* gnu/packages/aux-files/emacs/guix-emacs.el
(guix-emacs-autoload-packages): Reload subdirs.el files unless NO-RELOAD is
provided. Update doc.
* doc/guix.texi (Application Setup): Document that
'guix-emacs-autoload-packages' can be invoked interactively to auto-reload
newly installed Emacs packages.
* gnu/packages/emacs.scm (emacs) [arguments] <phases>: Call
guix-emacs-autoload-packages with an argument in the site-start.el file.
---
Changes in v3:
- Invert argument logic of guix-emacs-autoload-packages
- Drop the guix-emacs-autoload-packages-called state variable
- Adjust site-start.el file in Emacs package
Changes in v2:
- Safely load subdirs.el files
- Add 'reload' prefix argument as override for guix-emacs-autoload-packages
doc/guix.texi | 11 +++++++----
gnu/packages/aux-files/emacs/guix-emacs.el | 15 ++++++++++++---
gnu/packages/emacs.scm | 2 +-
3 files changed, 20 insertions(+), 8 deletions(-)
diff --git a/doc/guix.texi b/doc/guix.texi
index 04e5875925..939e669fee 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -2167,12 +2167,15 @@ Application Setup
Emacs through the @env{EMACSLOADPATH} environment variable, which is
set when installing Emacs itself.
+@cindex guix-emacs-autoload-packages, refreshing Emacs packages
Additionally, autoload definitions are automatically evaluated at the
initialization of Emacs, by the Guix-specific
-@code{guix-emacs-autoload-packages} procedure. If, for some reason, you
-want to avoid auto-loading the Emacs packages installed with Guix, you
-can do so by running Emacs with the @option{--no-site-file} option
-(@pxref{Init File,,, emacs, The GNU Emacs Manual}).
+@code{guix-emacs-autoload-packages} procedure. This procedure can be
+interactively invoked to have newly installed Emacs packages discovered,
+without having to restart Emacs. If, for some reason, you want to avoid
+auto-loading the Emacs packages installed with Guix, you can do so by
+running Emacs with the @option{--no-site-file} option (@pxref{Init
+File,,, emacs, The GNU Emacs Manual}).
@quotation Note
Emacs can now compile packages natively. Under the default
diff --git a/gnu/packages/aux-files/emacs/guix-emacs.el b/gnu/packages/aux-files/emacs/guix-emacs.el
index 84284dde39..c253e64df8 100644
--- a/gnu/packages/aux-files/emacs/guix-emacs.el
+++ b/gnu/packages/aux-files/emacs/guix-emacs.el
@@ -65,12 +65,21 @@ The files in the list do not have extensions (.el, .elc)."
(guix-emacs--non-core-load-path))))
;;;###autoload
-(defun guix-emacs-autoload-packages ()
+(defun guix-emacs-autoload-packages (&optional no-reload)
"Autoload Emacs packages found in EMACSLOADPATH.
'Autoload' means to load the 'autoloads' files matching
-`guix-emacs-autoloads-regexp'."
- (interactive)
+`guix-emacs-autoloads-regexp'. By default, the subdirs.el files
+found on the load path are reloaded to discover newly installed
+packages, unless NO-RELOAD is provided."
+ (interactive "P")
+ ;; Reload the subdirs.el files such as the one generated by the Guix profile
+ ;; hook, so that newly installed Emacs packages located under
+ ;; sub-directories are put on the load-path without having to restart Emacs.
+ (unless no-reload
+ (mapc #'guix-emacs--load-file-no-error (guix-emacs--subdirs-files))
+ (setq load-path (delete-dups load-path)))
+
(let ((autoloads (mapcan #'guix-emacs-find-autoloads
(guix-emacs--non-core-load-path))))
(mapc #'guix-emacs--load-file-no-error autoloads)))
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index d3689c2474..d9af6b96a7 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -244,7 +244,7 @@ (define-public emacs
(display
(string-append
"(when (require 'guix-emacs nil t)\n"
- " (guix-emacs-autoload-packages)\n"
+ " (guix-emacs-autoload-packages 'no-reload)\n"
" (advice-add 'package-load-all-descriptors"
" :after #'guix-emacs-load-package-descriptors))"))))
;; Remove the extraneous subdirs.el file, as it causes Emacs to
--
2.41.0
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Sat, 02 Sep 2023 04:50:02 GMT)
Full text and
rfc822 format available.
Message #56 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Am Freitag, dem 01.09.2023 um 00:53 -0400 schrieb Maxim Cournoyer:
> This fixes a regression introduced with 79cfe30f3 ("build-system:
> emacs: Use subdirectories again.") which caused the
> 'guix-emacs-autoload-packages' to no longer be able to autoload all
> packages.
>
> * gnu/packages/aux-files/emacs/guix-emacs.el
> (guix-emacs-autoload-packages): Reload subdirs.el files unless NO-
> RELOAD is provided. Update doc.
> * doc/guix.texi (Application Setup): Document that
> 'guix-emacs-autoload-packages' can be invoked interactively to auto-
> reload newly installed Emacs packages.
> * gnu/packages/emacs.scm (emacs) [arguments] <phases>: Call
> guix-emacs-autoload-packages with an argument in the site-start.el
> file.
>
> ---
>
> Changes in v3:
> - Invert argument logic of guix-emacs-autoload-packages
> - Drop the guix-emacs-autoload-packages-called state variable
> - Adjust site-start.el file in Emacs package
>
> Changes in v2:
> - Safely load subdirs.el files
> - Add 'reload' prefix argument as override for guix-emacs-autoload-
> packages
>
> doc/guix.texi | 11 +++++++----
> gnu/packages/aux-files/emacs/guix-emacs.el | 15 ++++++++++++---
> gnu/packages/emacs.scm | 2 +-
> 3 files changed, 20 insertions(+), 8 deletions(-)
Thanks, LGTM. I've tested this by dropping almost all parts of load-
path and calling (guix-emacs-autoload-packages), it appears to do
what's promised. Queued locally for emacs-next and followed up with a
patch that fixes the compilation warnings coming from the docstrings.
Cheers
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Sun, 03 Sep 2023 17:27:01 GMT)
Full text and
rfc822 format available.
Message #59 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Hi Liliana,
Liliana Marie Prikler <liliana.prikler <at> gmail.com> writes:
[...]
> Thanks, LGTM. I've tested this by dropping almost all parts of load-
> path and calling (guix-emacs-autoload-packages), it appears to do
> what's promised. Queued locally for emacs-next and followed up with a
> patch that fixes the compilation warnings coming from the docstrings.
Sounds good, thank you for testing it!
About warnings, when I byte compile guix-emacs.el, all I see is:
--8<---------------cut here---------------start------------->8---
Compiling file /home/maxim/src/guix/gnu/packages/aux-files/emacs/guix-emacs.el at Sun Sep 3 10:50:19 2023
guix-emacs.el:83:39: Warning: reference to free variable
‘treesit-extra-load-path’
guix-emacs.el:83:39: Warning: assignment to free variable
‘treesit-extra-load-path’
--8<---------------cut here---------------end--------------->8---
I don't know how to fix those; they seem harmless since their use is
enclosed in a (with-eval-after-load 'treesit ...) expression.
--
Thanks,
Maxim
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Sun, 03 Sep 2023 20:00:02 GMT)
Full text and
rfc822 format available.
Message #62 received at 65575 <at> debbugs.gnu.org (full text, mbox):
Am Sonntag, dem 03.09.2023 um 10:51 -0400 schrieb Maxim Cournoyer:
> Hi Liliana,
>
> Liliana Marie Prikler <liliana.prikler <at> gmail.com> writes:
>
> [...]
>
> > Thanks, LGTM. I've tested this by dropping almost all parts of
> > load-path and calling (guix-emacs-autoload-packages), it appears to
> > do what's promised. Queued locally for emacs-next and followed up
s/emacs-next/emacs-team/
Sorry for the confusion.
> > with a patch that fixes the compilation warnings coming from the
> > docstrings.
>
> Sounds good, thank you for testing it!
>
> About warnings, when I byte compile guix-emacs.el, all I see is:
>
> --8<---------------cut here---------------start------------->8---
>
> Compiling file /home/maxim/src/guix/gnu/packages/aux-
> files/emacs/guix-emacs.el at Sun Sep 3 10:50:19 2023
> guix-emacs.el:83:39: Warning: reference to free variable
> ‘treesit-extra-load-path’
> guix-emacs.el:83:39: Warning: assignment to free variable
> ‘treesit-extra-load-path’
> --8<---------------cut here---------------end--------------->8---
>
> I don't know how to fix those; they seem harmless since their use is
> enclosed in a (with-eval-after-load 'treesit ...) expression.
Yeah, I'm on Emacs 29 with tree-sitter baked in, so I see another set
of warnings (emacs-team vs master strikes again, it seems)
Cheers
Reply sent
to
Liliana Marie Prikler <liliana.prikler <at> gmail.com>
:
You have taken responsibility.
(Sat, 09 Sep 2023 08:21:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
:
bug acknowledged by developer.
(Sat, 09 Sep 2023 08:21:02 GMT)
Full text and
rfc822 format available.
Message #67 received at 65575-done <at> debbugs.gnu.org (full text, mbox):
Am Sonntag, dem 03.09.2023 um 21:59 +0200 schrieb Liliana Marie
Prikler:
> Am Sonntag, dem 03.09.2023 um 10:51 -0400 schrieb Maxim Cournoyer:
> > Hi Liliana,
> >
> > Liliana Marie Prikler <liliana.prikler <at> gmail.com> writes:
> >
> > [...]
> >
> > > Queued locally for emacs-next and followed up
> s/emacs-next/emacs-team/
s/Queued locally/Pushed/
Cheers
Information forwarded
to
bug-guix <at> gnu.org
:
bug#65575
; Package
guix
.
(Sat, 09 Sep 2023 13:05:01 GMT)
Full text and
rfc822 format available.
Message #70 received at 65575-done <at> debbugs.gnu.org (full text, mbox):
Hello,
Liliana Marie Prikler <liliana.prikler <at> gmail.com> writes:
> Am Sonntag, dem 03.09.2023 um 21:59 +0200 schrieb Liliana Marie
> Prikler:
>> Am Sonntag, dem 03.09.2023 um 10:51 -0400 schrieb Maxim Cournoyer:
>> > Hi Liliana,
>> >
>> > Liliana Marie Prikler <liliana.prikler <at> gmail.com> writes:
>> >
>> > [...]
>> >
>> > > Queued locally for emacs-next and followed up
>> s/emacs-next/emacs-team/
> s/Queued locally/Pushed/
Thank you!
--
Thanks,
Maxim
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 08 Oct 2023 11:24:10 GMT)
Full text and
rfc822 format available.
This bug report was last modified 1 year and 216 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.