[PATCH emacs-guix 0/4] Refresh package emacs-guix

  • Open
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Nicolas Graves
Owner
unassigned
Submitted by
Nicolas Graves
Severity
normal

Debbugs page

Nicolas Graves wrote 3 weeks ago
(address . guix-patches@gnu.org)(address . ludo@gnu.org)(name . Nicolas Graves)(address . ngraves@ngraves.fr)
20250303020636.3461-1-ngraves@ngraves.fr
This is a series of refreshing commits for emacs-guix.

This is done in an effort to port emacs-guix to
guile-ares-rs/emacs-arei backend, currently in progress here :

This is still a WIP, I'd still like to replace old references to
guix-environment by references to guix shell at least. I'm not able
to test all changes, since guix-command seems to be broken (before
this patch series I mean).

Thus, I invite users of emacs-guix to try that series and report any
bug that could have been caused by it.

Nicolas Graves (5):
Switch to transient
Improve most docstrings
Remove dash dependency, introduce llama library
Use a development channel instead of guix.scm
Update NEWS

.guix-channel | 3 +
NEWS | 10 +
README | 2 +-
guix.scm => channel/emacs-guix-channel.scm | 69 +++----
channel/emacs-guix-channel.scm.next | 104 ++++++++++
configure.ac | 32 +--
doc/emacs-guix.texi | 59 +++---
doc/htmlxref.cnf | 6 +-
elisp/guix-about.el | 2 +-
elisp/guix-build-config.el.in | 7 +-
elisp/guix-build-log.el | 28 +--
elisp/guix-command.el | 162 ++++++++-------
elisp/guix-config.el | 2 +-
elisp/guix-default-config.el | 2 +-
elisp/guix-external.el | 12 +-
elisp/guix-geiser.el | 9 +-
elisp/guix-graph.el | 2 +-
elisp/guix-guile.el | 6 +-
elisp/guix-help-vars.el | 37 ++--
elisp/guix-help.el | 15 +-
elisp/guix-license.el | 3 +-
elisp/guix-misc.el | 24 ++-
elisp/guix-package.el | 2 +-
elisp/guix-pcomplete.el | 15 +-
elisp/guix-popup.el | 227 ---------------------
elisp/guix-prettify.el | 4 +-
elisp/guix-profiles.el | 32 +--
elisp/guix-read.el | 8 +-
elisp/guix-repl.el | 43 ++--
elisp/guix-transient.el | 187 +++++++++++++++++
elisp/guix-ui-generation.el | 62 +++---
elisp/guix-ui-license.el | 18 +-
elisp/guix-ui-lint-checker.el | 15 +-
elisp/guix-ui-messages.el | 16 +-
elisp/guix-ui-package-location.el | 6 +-
elisp/guix-ui-package.el | 104 +++++-----
elisp/guix-ui-profile.el | 65 +++---
elisp/guix-ui-service-location.el | 6 +-
elisp/guix-ui-service.el | 32 ++-
elisp/guix-ui-store-item.el | 46 +++--
elisp/guix-ui-system-generation.el | 24 ++-
elisp/guix-ui-system.el | 17 +-
elisp/guix-ui.el | 16 +-
elisp/guix-utils.el | 92 ++++-----
elisp/guix.el | 2 +-
elisp/local.mk | 10 +-
46 files changed, 895 insertions(+), 750 deletions(-)
create mode 100644 .guix-channel
rename guix.scm => channel/emacs-guix-channel.scm (50%)
create mode 100644 channel/emacs-guix-channel.scm.next
delete mode 100644 elisp/guix-popup.el
create mode 100644 elisp/guix-transient.el

--
2.48.1
Nicolas Graves wrote 3 weeks ago
[PATCH 2/5] Improve most docstrings
(address . 76699@debbugs.gnu.org)(name . Nicolas Graves)(address . ngraves@ngraves.fr)
20250303020932.4194-2-ngraves@ngraves.fr
This is to decrease the number of flymake warnings and better address
serious warnings.
---
elisp/guix-about.el | 2 +-
elisp/guix-build-config.el.in | 7 ++-
elisp/guix-build-log.el | 28 ++++-----
elisp/guix-command.el | 58 +++++++++----------
elisp/guix-config.el | 2 +-
elisp/guix-default-config.el | 2 +-
elisp/guix-external.el | 12 ++--
elisp/guix-geiser.el | 9 +--
elisp/guix-graph.el | 2 +-
elisp/guix-guile.el | 6 +-
elisp/guix-help-vars.el | 37 ++++++------
elisp/guix-help.el | 12 ++--
elisp/guix-license.el | 3 +-
elisp/guix-misc.el | 24 ++++----
elisp/guix-package.el | 2 +-
elisp/guix-pcomplete.el | 15 ++---
elisp/guix-prettify.el | 4 +-
elisp/guix-profiles.el | 32 +++++------
elisp/guix-read.el | 8 ++-
elisp/guix-repl.el | 37 ++++++------
elisp/guix-ui-generation.el | 61 ++++++++++++--------
elisp/guix-ui-license.el | 18 +++---
elisp/guix-ui-lint-checker.el | 15 +++--
elisp/guix-ui-messages.el | 16 ++++--
elisp/guix-ui-package-location.el | 6 +-
elisp/guix-ui-package.el | 92 ++++++++++++++++--------------
elisp/guix-ui-profile.el | 37 +++++++-----
elisp/guix-ui-service-location.el | 6 +-
elisp/guix-ui-service.el | 32 +++++++----
elisp/guix-ui-store-item.el | 46 +++++++++------
elisp/guix-ui-system-generation.el | 24 +++++---
elisp/guix-ui-system.el | 17 ++++--
elisp/guix-ui.el | 16 +++---
elisp/guix-utils.el | 91 ++++++++++++++---------------
34 files changed, 430 insertions(+), 349 deletions(-)

Toggle diff (424 lines)
diff --git a/elisp/guix-about.el b/elisp/guix-about.el
index e0de219..6e1168a 100644
--- a/elisp/guix-about.el
+++ b/elisp/guix-about.el
@@ -107,7 +107,7 @@ Return nil if the image cannot be found."
(bui-newline)))))))
(defun guix-about-insert-content ()
- "Insert Emacs-Guix 'about' info into the current buffer."
+ "Insert Emacs-Guix \\='about\\=' info into the current buffer."
(guix-insert-logo)
(apply #'fancy-splash-insert guix-about-specifications)
(goto-char (point-min))
diff --git a/elisp/guix-build-config.el.in b/elisp/guix-build-config.el.in
index a32059a..af21dc8 100644
--- a/elisp/guix-build-config.el.in
+++ b/elisp/guix-build-config.el.in
@@ -18,6 +18,8 @@
;; You should have received a copy of the GNU General Public License
;; along with Emacs-Guix. If not, see <http://www.gnu.org/licenses/>.
+;;; Commentary:
+
;;; Code:
(defconst guix-config-name "@PACKAGE_NAME@"
@@ -65,8 +67,7 @@
"Directory with Guix compiled (*.go) files.")
(defconst guix-config-guile-program "@GUILE@"
- "Name of the 'guile' executable defined at configure time.")
+ "Name of the \\='guile\\=' executable defined at configure time.")
(provide 'guix-build-config)
-
-;;; guix-build-config.el ends here
+;;; guix-build-config.el.in ends here
diff --git a/elisp/guix-build-log.el b/elisp/guix-build-log.el
index 7d2bce5..ac4f428 100644
--- a/elisp/guix-build-log.el
+++ b/elisp/guix-build-log.el
@@ -93,12 +93,12 @@
(defface guix-build-log-phase-success
'((t))
- "Face for the 'succeeded' word of a phase line."
+ "Face for the \"succeeded\" word of a phase line."
:group 'guix-build-log-faces)
(defface guix-build-log-phase-fail
'((t :inherit error))
- "Face for the 'failed' word of a phase line."
+ "Face for the \"failed\" word of a phase line."
:group 'guix-build-log-faces)
(defface guix-build-log-phase-seconds
@@ -116,7 +116,7 @@
(defvar guix-build-log-phase-start-regexp
(concat "^starting phase " guix-build-log-phase-name-regexp)
- "Regexp for the start line of a 'build' phase.")
+ "Regexp for the start line of a \\='build\\=' phase.")
(defvar guix-build-log-imenu-generic-expression
`((nil ,guix-build-log-phase-start-regexp 1))
@@ -125,8 +125,8 @@
(defun guix-build-log-title-regexp (&optional state)
"Return regexp for the log title.
STATE is a symbol denoting a state of the title. It should be
-`start', `fail', `success' or `nil' (for a regexp matching any
-state)."
+\\='start\\=', \\='fail\\=', \\='success\\=' or \\='nil\\=' (for a
+regexp matching any state)."
(let* ((word-rx (rx (1+ (any word "-"))))
(state-rx (cond ((eq state 'start) (concat word-rx "started"))
((eq state 'success) (concat word-rx "succeeded"))
@@ -137,9 +137,10 @@ state)."
t)))
(defun guix-build-log-phase-end-regexp (&optional state)
- "Return regexp for the end line of a 'build' phase.
+ "Return regexp for the end line of a \\='build\\=' phase.
STATE is a symbol denoting how a build phase was ended. It should be
-`fail', `success' or `nil' (for a regexp matching any state)."
+\\='fail\\=', \\='success\\=' or \\='nil\\=' (for a regexp matching
+any state)."
(let ((state-rx (cond ((eq state 'success) "succeeded")
((eq state 'fail) "failed")
(t (regexp-opt '("succeeded" "failed"))))))
@@ -153,7 +154,7 @@ STATE is a symbol denoting how a build phase was ended. It should be
;; For efficiency, it is better to have a regexp for the general line
;; of the phase end, then to call the function all the time.
(guix-build-log-phase-end-regexp)
- "Regexp for the end line of a 'build' phase.")
+ "Regexp for the end line of a \\='build\\=' phase.")
(defvar guix-build-log-font-lock-keywords
`((,(guix-build-log-title-regexp 'start)
@@ -192,9 +193,9 @@ STATE is a symbol denoting how a build phase was ended. It should be
(define-key map (kbd "<backtab>") 'guix-build-log-phase-toggle-all)
(define-key map [(shift tab)] 'guix-build-log-phase-toggle-all)
map)
- "Parent keymap for 'build-log' buffers.
+ "Parent keymap for \\='build-log\\=' buffers.
For `guix-build-log-mode' this map is used as is.
-For `guix-build-log-minor-mode' this map is prefixed with 'C-c'.")
+For `guix-build-log-minor-mode' this map is prefixed with \`C-c'.")
(defvar guix-build-log-mode-map
(let ((map (make-sparse-keymap)))
@@ -214,8 +215,9 @@ For `guix-build-log-minor-mode' this map is prefixed with 'C-c'.")
(defun guix-build-log-phase-start (&optional with-header?)
"Return the start point of the current build phase.
-If WITH-HEADER? is non-nil, do not skip 'starting phase ...' header.
-Return nil, if there is no phase start before the current point."
+If WITH-HEADER? is non-nil, do not skip \\='starting phase ...\\='
+header. Return nil, if there is no phase start before the current
+point."
(save-excursion
(end-of-line)
(when (re-search-backward guix-build-log-phase-start-regexp nil t)
@@ -343,7 +345,7 @@ When Guix Build Log minor mode is enabled, it highlights build
log in the current buffer. This mode can be enabled
programmatically using hooks, like this:
- (add-hook 'shell-mode-hook 'guix-build-log-minor-mode)
+ (add-hook \\='shell-mode-hook \\='guix-build-log-minor-mode)
\\{guix-build-log-minor-mode-map}"
:init-value nil
diff --git a/elisp/guix-command.el b/elisp/guix-command.el
index affda4e..a205418 100644
--- a/elisp/guix-command.el
+++ b/elisp/guix-command.el
@@ -80,7 +80,7 @@
(defvar guix-command-complex-with-shared-arguments
'("potluck" "system")
"List of guix commands which have subcommands with shared options.
-I.e., 'guix foo --help' is the same as 'guix foo bar --help'.")
+I.e., \\='guix foo --help\\=' is the same as \\='guix foo bar --help\\='.")
(defun guix-command-action-name (&optional commands &rest name-parts)
"Return name of action function for guix COMMANDS."
@@ -484,7 +484,7 @@ to be modified."
argument))
(defun guix-command-improve-arguments (arguments commands)
- "Return ARGUMENTS for 'guix COMMANDS ...' modified for transient interface."
+ "Return ARGUMENTS for \\='guix COMMANDS ...\\=' modified for transient interface."
(let ((improvers (cons 'guix-command-improve-common-argument
(bui-assoc-value guix-command-argument-improvers
commands))))
@@ -493,7 +493,7 @@ to be modified."
arguments)))
(defun guix-command-parse-arguments (&optional commands)
- "Return a list of parsed 'guix COMMANDS ...' arguments."
+ "Return a list of parsed \\='guix COMMANDS ...\\=' arguments."
(with-temp-buffer
(insert (guix-help-string commands))
(let (args)
@@ -585,7 +585,7 @@ to be modified."
:doc "build inputs of the specified packages"
:fun 'guix-read-package-names-string)))
"Alist of guix commands and additional arguments for them.
-These are 'fake' arguments that are not presented in 'guix' shell
+These are \\='fake\\=' arguments that are not presented in \\='guix\\=' shell
commands.")
(defun guix-command-additional-arguments (&optional commands)
@@ -601,7 +601,7 @@ commands.")
;; commands.
(defun guix-command--all-arguments (&optional commands)
- "Return list of all arguments for 'guix COMMANDS ...'."
+ "Return list of all arguments for \\='guix COMMANDS ...\\='."
(let ((parsed (guix-command-parse-arguments commands)))
(append (guix-command-improve-arguments parsed commands)
(guix-command-additional-arguments commands))))
@@ -612,7 +612,7 @@ commands.")
(defun guix-command-all-arguments (&optional commands)
;; Note: `guix-command-arguments' name cannot be used because function
;; with this name is generated by `transient-define-prefix'.
- "Return list of arguments for 'guix COMMANDS ...'."
+ "Return list of arguments for \\='guix COMMANDS ...\\='."
(let ((command (car commands)))
(if (member command
guix-command-complex-with-shared-arguments)
@@ -700,7 +700,7 @@ Each function is called on the returned arguments in turn.")
(defvar guix-command-rest-arg-regexp
(rx string-start "-- " (group (+ any)))
- "Regexp to match a string with the 'rest' arguments.")
+ "Regexp to match a string with the \\='rest\\=' arguments.")
(defun guix-command-replace-args (args predicate modifier)
"Replace arguments matching PREDICATE from ARGS.
@@ -740,39 +740,37 @@ arguments into multiple subarguments."
:group 1))
(defun guix-command-post-process-rest-multiple (args)
- "Modify ARGS by splitting '-- ARG ...' into multiple subarguments
-and moving them to the end of ARGS list.
-Remove '-- ' string."
+ "Modify ARGS and remove '-- ' string.
+Do that by splitting \\='-- ARG ...\\=' into multiple subarguments
+and moving them to the end of ARGS list."
(guix-command-post-process-matching-args
args guix-command-rest-arg-regexp
:group 1
:split? t))
(defun guix-command-post-process-rest-multiple-leave (args)
- "Modify ARGS by splitting '-- ARG ...' into multiple subarguments
-and moving them to the end of ARGS list.
-Leave '--' string as a separate argument."
+ "Modify ARGS and leave '--' string as a separate argument.
+Do that by splitting \\='-- ARG ...\\=' into multiple subarguments
+and moving them to the end of ARGS list."
(guix-command-post-process-matching-args
args guix-command-rest-arg-regexp
:split? t))
(defun guix-command-post-process-package-args (args)
- "Adjust transient ARGS for 'guix package' command."
+ "Adjust transient ARGS for \\='guix package\\=' command."
(guix-command-post-process-matching-args
args (rx string-start (or "--install " "--remove ") (+ any))
:split? t))
(defun guix-command-post-process-environment-packages (args)
- "Adjust transient ARGS for specified packages of 'guix environment'
-command."
+ "Adjust ARGS for specified packages of \\='guix environment\\=' command."
(guix-command-post-process-matching-args
args (rx string-start "++packages " (group (+ any)))
:group 1
:split? t))
(defun guix-command-post-process-environment-ad-hoc (args)
- "Adjust transient ARGS for '--ad-hoc' argument of 'guix environment'
-command."
+ "Adjust ARGS for '--ad-hoc' argument of \\='guix environment\\=' command."
(guix-command-post-process-matching-args
args (rx string-start "--ad-hoc " (+ any))
:split? t))
@@ -799,7 +797,7 @@ command."
:name "shell" :char ?s :doc "Run in shell")
(guix-command-make-argument
:name "copy" :char ?c :doc "Copy command line"))
- "List of default 'execute' action arguments.")
+ "List of default \\='execute\\=' action arguments.")
(defvar guix-command-additional-execute-arguments
(let ((graph-arg (guix-command-make-argument
@@ -813,10 +811,10 @@ command."
:name "view" :char ?v :doc "View map"))
(("system" "shepherd-graph") ,graph-arg)
(("system" "extension-graph") ,graph-arg)))
- "Alist of guix commands and additional 'execute' action arguments.")
+ "Alist of guix commands and additional \\='execute\\=' action arguments.")
(defun guix-command-execute-arguments (commands)
- "Return a list of 'execute' action arguments for COMMANDS."
+ "Return a list of \\='execute\\=' action arguments for COMMANDS."
(mapcar (lambda (arg)
(guix-command-modify-argument arg
:action? t
@@ -856,7 +854,7 @@ See also `guix-command-default-executors'.")
(bui-assoc-value guix-command-default-executors name)))
(defun guix-run-environment-command-in-repl (args)
- "Run 'guix ARGS ...' environment command in Guix REPL."
+ "Run \\='guix ARGS ...\\=' environment command in Guix REPL."
;; As 'guix environment' usually tries to run another process, it may
;; be fun but not wise to run this command in Geiser REPL.
(when (or (member "--dry-run" args)
@@ -871,7 +869,7 @@ Do you really want to execute this command in Geiser REPL? "
(guix-run-command-in-repl args)))
(defun guix-run-pull-command-in-repl (args)
- "Run 'guix ARGS ...' pull command in Guix REPL.
+ "Run \\='guix ARGS ...\\=' pull command in Guix REPL.
Perform pull-specific actions after operation, see
`guix-after-pull-hook' and `guix-update-after-pull'."
(guix-eval-in-repl
@@ -882,8 +880,8 @@ Perform pull-specific actions after operation, see
'pull)))
(defun guix-run-view-build-log (args)
- "Add --log-file to ARGS, run 'guix ARGS ...' build command, and
-open the log file(s)."
+ "Add --log-file to ARGS, run \\='guix ARGS ...\\=' build command.
+Then open the log file(s)."
(let* ((args (if (member "--log-file" args)
args
(cl-list* (car args) "--log-file" (cdr args))))
@@ -895,7 +893,7 @@ open the log file(s)."
(declare-function guix-make-view-graph "guix-graph" t)
(defun guix-run-view-graph (args)
- "Run 'guix ARGS ...' graph command, make the image and open it."
+ "Run \\='guix ARGS ...\\=' graph command, make the image and open it."
(require 'guix-graph)
(guix-make-view-graph
(if (member "--backend=d3js" args) "d3js" "graphviz")
@@ -909,7 +907,7 @@ open the log file(s)."
'guix-output-to-file args graph-file)))))))
(defun guix-run-view-size-map (args)
- "Run 'guix ARGS ...' size command, and open the map file."
+ "Run \\='guix ARGS ...\\=' size command, and open the map file."
(let* ((wished-map-file
(cl-some (lambda (arg)
(and (string-match "--map-file=\\(.+\\)" arg)
@@ -955,7 +953,7 @@ EXECUTOR function is called with the current command line arguments."
',commands (transient-args (transient-current-command))))))))
(defun guix-command-generate-popup-actions (actions &optional commands)
- "Generate 'popup' commands from ACTIONS arguments for guix COMMANDS."
+ "Generate \\='popup\\=' commands from ACTIONS arguments for guix COMMANDS."
(dolist (action actions)
(let ((fun (guix-command-argument-fun action)))
(unless (fboundp fun)
@@ -964,7 +962,7 @@ EXECUTOR function is called with the current command line arguments."
(list (guix-command-argument-name action)))))))))
(defun guix-command-generate-execute-actions (actions &optional commands)
- "Generate 'execute' commands from ACTIONS arguments for guix COMMANDS."
+ "Generate \\='execute\\=' commands from ACTIONS arguments for guix COMMANDS."
(dolist (action actions)
(let ((fun (guix-command-argument-fun action)))
(unless (fboundp fun)
@@ -974,7 +972,7 @@ EXECUTOR function is called with the current command line arguments."
,commands))))))
(defun guix-command-generate-prefix (name &optional commands)
- "Define NAME prefix with 'guix COMMANDS ...' interface."
+ "Define NAME prefix with \\='guix COMMANDS ...\\=' interface."
(let* ((command (car commands))
(man-page (concat "guix" (and command (concat "-" command))))
(doc (format "Transient for '%s' command."
diff --git a/elisp/guix-config.el b/elisp/guix-config.el
index 4506958..8cc1f6a 100644
--- a/elisp/guix-config.el
+++ b/elisp/guix-config.el
@@ -59,7 +59,7 @@
nil))
"Directory with Scheme files for Emacs-Guix package.
It should be a directory where Guile modules are placed, i.e. a
-directory with 'emacs-guix' sub-directory.")
+directory with \\='emacs-guix\\=' sub-directory.")
(defvar guix-image-directory
(or guix-config-image-directory
diff --git a/elisp/guix-default-config.el b/elisp/guix-default-config.el
index 77ffc83..4ec7a1c 100644
--- a/elisp/guix-default-config.el
+++ b/elisp/guix-default-config.el
@@ -59,7 +59,7 @@
"Directory with Guix compiled (*.go) files.")
(defconst guix-config-guile-program nil
- "Name of the 'guile' executable defined at configure time.")
+ "Name of the \\='guile\\=' executable defined at configure time.")
(provide 'guix-default-config)
diff --git a/elisp/guix-external.el b/elisp/guix-external.el
index c7e123b..d470c36 100644
--- a/elisp/guix-external.el
+++ b/elisp/guix-external.el
@@ -38,7 +38,7 @@
;; Avoid auto-compilation as it is slow and error-prone:
;; <https://notabug.org/alezost/emacs-guix/issues/2>.
"--no-auto-compile")
- "Name of the 'guile' executable used for Guix REPL.
+ "Name of the \\='guile\\=' executable used for Guix REPL.
May be either a string (the name of the executable) or a list of
strings of the form:
@@ -50,18 +50,18 @@ Where ARGS is a list of arguments to the guile program."
(defcustom guix-dot-program
(executable-find "dot")
- "Name of the 'dot' executable."
+ "Name of the \\='dot\\=' executable."
:type 'string
:group 'guix-external)
(defcustom guix-dot-default-arguments
'("-Tpng")
- "Default arguments for 'dot' program."
+ "Default arguments for \\='dot\\=' program."
:type '(repeat string)
:group 'guix-external)
(defcustom guix-dot-file-name-function #'guix-png-file-name
- "Function used to define a file name of a temporary 'dot' file.
+ "Function used to define a file name of a temporary \\='dot\\=' file.
The function is called without arguments."
:type '(choice (function-item guix-png-file-name)
(function :tag "Other function"))
@@ -82,11 +82,11 @@ If ARGS is nil, use `guix-dot-default-arguments'."
(funcall guix-dot-file-name-function))
(defun guix-png-file-name ()
- "Return '.png' file name in the `guix-temporary-directory'."
+ "Return '.png' file name in the variable `guix-temporary-directory'."
(guix-temporary-file-name "graph-" ".png"))
(defun guix-html-file-name ()
- "Return '.html' file name in the `guix-temporary-directory'."
+ "Return '.html' file name in the variable `guix-temporary-directory'."
(guix-temporary-file-name "graph-" ".html"))
(provide 'guix-external)
diff --git a/elisp/guix-geiser.el b/elisp/guix-geiser.el
index 7b503e5..8d96035 100644
--- a/elisp/guix-geiser.el
+++ b/elisp/guix-geiser.el
@@ -53,7 +53,7 @@ Return a list of strings with result values of evaluation."
Sorry, the eva
This message was truncated. Download the full message here.
Nicolas Graves wrote 3 weeks ago
[PATCH 3/5] Remove dash dependency, introduce llama library
(address . 76699@debbugs.gnu.org)(name . Nicolas Graves)(address . ngraves@ngraves.fr)
20250303020932.4194-3-ngraves@ngraves.fr
---
configure.ac | 16 ++++++++--------
doc/emacs-guix.texi | 8 ++++----
elisp/guix-help.el | 1 -
elisp/guix-repl.el | 6 +++---
elisp/guix-ui-generation.el | 1 -
elisp/guix-ui-package.el | 12 ++++++------
elisp/guix-ui-profile.el | 28 +++++++++++++++-------------
elisp/guix-ui-store-item.el | 2 --
elisp/guix-utils.el | 1 -
elisp/guix.el | 2 +-
elisp/local.mk | 4 ++--
11 files changed, 39 insertions(+), 42 deletions(-)

Toggle diff (300 lines)
diff --git a/configure.ac b/configure.ac
index 3461bb3..31c7328 100644
--- a/configure.ac
+++ b/configure.ac
@@ -109,12 +109,12 @@ AC_ARG_WITH([geiser-lispdir],
[geiserlispdir="no"])
AC_SUBST([geiserlispdir])
-AC_ARG_WITH([dash-lispdir],
- [AS_HELP_STRING([--with-dash-lispdir],
- [directory with dash.el file])],
- [dashlispdir="$withval"],
- [dashlispdir="no"])
-AC_SUBST([dashlispdir])
+AC_ARG_WITH([llama-lispdir],
+ [AS_HELP_STRING([--with-llama-lispdir],
+ [directory with llama.el file])],
+ [llamalispdir="$withval"],
+ [llamalispdir="no"])
+AC_SUBST([llamalispdir])
AC_ARG_WITH([bui-lispdir],
[AS_HELP_STRING([--with-bui-lispdir],
@@ -138,7 +138,7 @@ AC_ARG_WITH([transient-lispdir],
AC_SUBST([transientlispdir])
AM_CONDITIONAL([GEISER_DIR], [test "x$geiserlispdir" != "xno"])
-AM_CONDITIONAL([DASH_DIR], [test "x$dashlispdir" != "xno"])
+AM_CONDITIONAL([LLAMA_DIR], [test "x$llamalispdir" != "xno"])
AM_CONDITIONAL([BUI_DIR], [test "x$builispdir" != "xno"])
AM_CONDITIONAL([EDITINDIRECT_DIR], [test "x$editindirectlispdir" != "xno"])
AM_CONDITIONAL([TRANSIENT_DIR], [test "x$transientlispdir" != "xno"])
@@ -148,7 +148,7 @@ dnl byte-compilation. Otherwise, "emacs" will be used, and it will
dnl hopefully find these packages in its 'load-path'.
AM_CONDITIONAL([EMACS_Q],
[test "x$geiserlispdir" != "xno" -a \
- "x$dashlispdir" != "xno" -a \
+ "x$llamalispdir" != "xno" -a \
"x$builispdir" != "xno" -a \
"x$editindirectlispdir" != "xno" -a \
"x$transientlispdir" != "xno"])
diff --git a/doc/emacs-guix.texi b/doc/emacs-guix.texi
index 6bb3810..1953b09 100644
--- a/doc/emacs-guix.texi
+++ b/doc/emacs-guix.texi
@@ -176,8 +176,8 @@ from the Guix Guile code. So without Geiser, you can use the same
features as without Guix.
@item
-@uref{https://github.com/magnars/dash.el, dash library}, version
-2.11.0 or later.
+@uref{https://github.com/tarsius/llama, llama library}, version
+0.6.1 or later.
@item
@uref{https://gitlab.com/alezost-emacs/bui, BUI library}, version
@@ -1091,8 +1091,8 @@ easy accessible key combination, for example, to @kbd{@key{super}-g}:
(global-set-key (kbd "s-g") 'guix)
@end example
-@node Guix Keyboard-driven Menu
-@section Guix Keyboard-driven Menu
+@node Keyboard-driven Menu
+@section Keyboard-driven Menu
@findex guix-command
There is one rather special transient suffix in @kbd{M-x@tie{}guix}. It
diff --git a/elisp/guix-help.el b/elisp/guix-help.el
index 53ccd3a..f8be213 100644
--- a/elisp/guix-help.el
+++ b/elisp/guix-help.el
@@ -23,7 +23,6 @@
;;; Code:
-(require 'dash)
(require 'bui)
(require 'guix nil t)
(require 'guix-utils)
diff --git a/elisp/guix-repl.el b/elisp/guix-repl.el
index 846db60..0ebf603 100644
--- a/elisp/guix-repl.el
+++ b/elisp/guix-repl.el
@@ -48,7 +48,6 @@
;;; Code:
-(require 'dash)
(require 'geiser-mode)
(require 'geiser-guile)
(require 'guix nil t)
@@ -57,6 +56,7 @@
(require 'guix-external)
(require 'guix-profiles)
(require 'guix-utils)
+(require 'llama)
(defvar guix-load-path nil
"Directory or a list of directories prepended to Guile's `%load-path'.
@@ -209,8 +209,8 @@ After setting this variable, you need to kill
(lcp (if guix-load-compiled-path
(guix-list-maybe guix-load-compiled-path)
lp)))
- (append (--mapcat (list "-L" (guix-file-name it)) lp)
- (--mapcat (list "-C" (guix-file-name it)) lcp))))
+ (append (apply #'append (list "-L" (##guix-file-name %1)) lp)
+ (apply #'append (list "-C" (##guix-file-name %1)) lcp))))
"-L" ,guix-scheme-directory
,@(and guix-config-scheme-compiled-directory
(list "-C" guix-config-scheme-compiled-directory))
diff --git a/elisp/guix-ui-generation.el b/elisp/guix-ui-generation.el
index 7d10d90..ba28814 100644
--- a/elisp/guix-ui-generation.el
+++ b/elisp/guix-ui-generation.el
@@ -25,7 +25,6 @@
;;; Code:
(require 'cl-lib)
-(require 'dash)
(require 'bui)
(require 'guix nil t)
(require 'guix-ui)
diff --git a/elisp/guix-ui-package.el b/elisp/guix-ui-package.el
index f861820..293e597 100644
--- a/elisp/guix-ui-package.el
+++ b/elisp/guix-ui-package.el
@@ -25,7 +25,6 @@
;;; Code:
(require 'cl-lib)
-(require 'dash)
(require 'bui)
(require 'guix nil t)
(require 'guix-ui)
@@ -39,6 +38,7 @@
(require 'guix-location)
(require 'guix-package)
(require 'guix-profiles)
+(require 'llama)
(guix-ui-define-entry-type package)
(guix-ui-define-entry-type output)
@@ -102,14 +102,14 @@ is found and `guix-package-list-show-single' is nil."
(defun guix-package-entry-installed-outputs (entry)
"Return a list of installed outputs for the package ENTRY."
- (--map (bui-entry-non-void-value it 'output)
- (bui-entry-non-void-value entry 'installed)))
+ (mapcar (##bui-entry-non-void-value %1 'output)
+ (bui-entry-non-void-value entry 'installed)))
(defun guix-read-package-name-from-entries (entries)
"Prompt for a package name and return it.
Names are completed from package ENTRIES."
(completing-read "Package: "
- (--map (bui-entry-value it 'name) entries)))
+ (mapcar (##bui-entry-value %1 'name) entries)))
(defun guix-read-package-entry-by-name (&optional entries)
"Return an entry from package ENTRIES (current entries by default).
@@ -1165,8 +1165,8 @@ Colorize it with an appropriate face if needed."
(defun guix-package-list-get-installed-outputs (installed &optional _)
"Return string with outputs from INSTALLED entries."
(bui-get-string
- (--map (bui-entry-non-void-value it 'output)
- installed)))
+ (mapcar (##bui-entry-non-void-value %1 'output)
+ installed)))
(defun guix-package-list-marking-check ()
"Signal an error if marking is disabled for the current buffer."
diff --git a/elisp/guix-ui-profile.el b/elisp/guix-ui-profile.el
index 2f17b38..0923ba5 100644
--- a/elisp/guix-ui-profile.el
+++ b/elisp/guix-ui-profile.el
@@ -26,13 +26,13 @@
;;; Code:
-(require 'dash)
(require 'bui)
(require 'guix nil t)
(require 'guix-profiles)
(require 'guix-read)
(require 'guix-utils)
(require 'guix-misc)
+(require 'llama)
(guix-define-groups profile)
@@ -55,15 +55,15 @@ properly.")
"Return a list of all profiles."
(or guix-profiles
(setq guix-profiles
- (--filter
- (and it (file-exists-p it))
+ (seq-filter
+ (##and %1 (file-exists-p %1))
(delete-dups
- (-cons* guix-default-user-profile
- guix-default-pulled-profile
- guix-system-profile
- guix-home-profile
- (--when-let (getenv "GUIX_PROFILE")
- (guix-file-name it))
+ (append (list guix-default-user-profile
+ guix-default-pulled-profile
+ guix-system-profile
+ guix-home-profile
+ (when-let ((profile (getenv "GUIX_PROFILE")))
+ (guix-file-name profile)))
(guix-eval-read "(user-profiles)")))))))
(defun guix-profile->entry (profile)
@@ -107,8 +107,8 @@ are multiple entries, prompt for a profile name and return it."
(or entries (setq entries (bui-current-entries)))
(if (cdr entries)
(completing-read "Profile: "
- (--map (bui-entry-value it 'profile)
- entries))
+ (mapcar (##bui-entry-value %1 'profile)
+ entries))
(bui-entry-value (car entries) 'profile)))
@@ -208,8 +208,10 @@ get the information."
(lambda (entry)
(let ((id (bui-entry-id entry)))
(cons `(current . ,(equal id current-id))
- (--remove-first (eq (car it) 'current)
- entry))))
+ (seq-remove-at-position
+ (seq-filter (##eq (car %1) 'current)
+ entry)
+ 0))))
(bui-current-entries))))
(setf (bui-item-entries bui-item)
new-entries))
diff --git a/elisp/guix-ui-store-item.el b/elisp/guix-ui-store-item.el
index 13a2d78..91c1d96 100644
--- a/elisp/guix-ui-store-item.el
+++ b/elisp/guix-ui-store-item.el
@@ -1,7 +1,6 @@
;;; guix-ui-store-item.el --- Interface to display store items -*- lexical-binding: t -*-
;; Copyright © 2018 Alex Kost <alezost@gmail.com>
-;; Copyright © 2025 Nicolas Graves <ngraves@ngraves.fr>
;; This file is part of Emacs-Guix.
@@ -27,7 +26,6 @@
(require 'cl-lib)
(require 'ffap)
-(require 'dash)
(require 'bui)
(require 'guix-package)
(require 'guix-guile)
diff --git a/elisp/guix-utils.el b/elisp/guix-utils.el
index 5535eb9..1d0db3f 100644
--- a/elisp/guix-utils.el
+++ b/elisp/guix-utils.el
@@ -24,7 +24,6 @@
;;; Code:
(require 'cl-lib)
-(require 'dash)
(require 'bui-utils)
(require 'guix nil t)
diff --git a/elisp/guix.el b/elisp/guix.el
index 2686a24..6e0ebc8 100644
--- a/elisp/guix.el
+++ b/elisp/guix.el
@@ -6,7 +6,7 @@
;; Version: 0.5.2
;; URL: https://emacs-guix.gitlab.io/website/
;; Keywords: tools
-;; Package-Requires: ((emacs "24.3") (dash "2.11.0") (geiser "0.8") (bui "1.2.0") (transient "0.8.4") (edit-indirect "0.1.4"))
+;; Package-Requires: ((emacs "24.3") (llama "0.6.1") (geiser "0.8") (bui "1.2.0") (transient "0.8.4") (edit-indirect "0.1.4"))
;; This file is part of Emacs-Guix.
diff --git a/elisp/local.mk b/elisp/local.mk
index 4efbae5..b5b10c0 100644
--- a/elisp/local.mk
+++ b/elisp/local.mk
@@ -28,8 +28,8 @@ if GEISER_DIR
AM_ELCFLAGS += -L "$(geiserlispdir)"
endif
-if DASH_DIR
- AM_ELCFLAGS += -L "$(dashlispdir)"
+if LLAMA_DIR
+ AM_ELCFLAGS += -L "$(llamalispdir)"
endif
if BUI_DIR
--
2.48.1
Nicolas Graves wrote 3 weeks ago
[PATCH 1/5] Switch to transient
(address . 76699@debbugs.gnu.org)(name . Nicolas Graves)(address . ngraves@ngraves.fr)
20250303020932.4194-1-ngraves@ngraves.fr
---
README | 2 +-
configure.ac | 16 +--
doc/emacs-guix.texi | 55 +++++-----
doc/htmlxref.cnf | 6 +-
elisp/guix-command.el | 114 ++++++++++----------
elisp/guix-help.el | 2 +-
elisp/guix-popup.el | 227 ----------------------------------------
elisp/guix-transient.el | 187 +++++++++++++++++++++++++++++++++
elisp/guix.el | 2 +-
elisp/local.mk | 6 +-
10 files changed, 288 insertions(+), 329 deletions(-)
delete mode 100644 elisp/guix-popup.el
create mode 100644 elisp/guix-transient.el

Toggle diff (457 lines)
diff --git a/README b/README
index 55a6956..6a63f97 100644
--- a/README
+++ b/README
@@ -34,7 +34,7 @@ In short, Emacs-Guix provides the following features:
+ [[/gnu/store]] items
-- Magit-like popup interface for all Emacs-Guix and Guix shell commands
+- Magit-like keyboard-driven menu for all Emacs-Guix and Guix shell commands
(=M-x guix=).
- Modes to view logs of package builds (=guix-build-log-mode= and
diff --git a/configure.ac b/configure.ac
index dd1de4b..3461bb3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -130,18 +130,18 @@ AC_ARG_WITH([editindirect-lispdir],
[editindirectlispdir="no"])
AC_SUBST([editindirectlispdir])
-AC_ARG_WITH([popup-lispdir],
- [AS_HELP_STRING([--with-popup-lispdir],
- [directory with magit-popup.el file])],
- [popuplispdir="$withval"],
- [popuplispdir="no"])
-AC_SUBST([popuplispdir])
+AC_ARG_WITH([transient-lispdir],
+[AS_HELP_STRING([--with-transient-lispdir],
+ [directory with transient.el file])],
+ [transientlispdir="$withval"],
+ [transientlispdir="no"])
+AC_SUBST([transientlispdir])
AM_CONDITIONAL([GEISER_DIR], [test "x$geiserlispdir" != "xno"])
AM_CONDITIONAL([DASH_DIR], [test "x$dashlispdir" != "xno"])
AM_CONDITIONAL([BUI_DIR], [test "x$builispdir" != "xno"])
AM_CONDITIONAL([EDITINDIRECT_DIR], [test "x$editindirectlispdir" != "xno"])
-AM_CONDITIONAL([POPUP_DIR], [test "x$popuplispdir" != "xno"])
+AM_CONDITIONAL([TRANSIENT_DIR], [test "x$transientlispdir" != "xno"])
dnl If all elisp dependencies are specified, we can use "emacs -Q" for
dnl byte-compilation. Otherwise, "emacs" will be used, and it will
@@ -151,7 +151,7 @@ AM_CONDITIONAL([EMACS_Q],
"x$dashlispdir" != "xno" -a \
"x$builispdir" != "xno" -a \
"x$editindirectlispdir" != "xno" -a \
- "x$popuplispdir" != "xno"])
+ "x$transientlispdir" != "xno"])
dnl ----------------------------------------------------------------
diff --git a/doc/emacs-guix.texi b/doc/emacs-guix.texi
index 3219354..6bb3810 100644
--- a/doc/emacs-guix.texi
+++ b/doc/emacs-guix.texi
@@ -53,7 +53,7 @@ A copy of the license is available at
* System:: Interface for @code{operating-system} and services.
* Store Items:: Interface for store items.
* Package Licenses:: Interface for licenses of packages.
-* Popup Interface:: Magit-like interface for Emacs-Guix commands.
+* Keyboard-driven Menu:: Magit-like interface for Emacs-Guix commands.
* Prettify Mode:: Abbreviating @file{/gnu/store/@dots{}} file names.
* Prettify Variables:: Split and indent Shell variables.
* Build Log Mode:: Highlighting Guix build logs.
@@ -77,8 +77,8 @@ Indexes
Emacs-Guix (also known as ``guix.el'') provides various interfaces and
tools related to the GNU Guix package manager.
-Call @kbd{M-x guix} if you prefer to dive in right away (@pxref{Popup
-Interface}).
+Call @kbd{M-x guix} if you prefer to dive in right away
+(@pxref{Keyboard-driven Menu}).
In short, Emacs-Guix provides the following features:
@@ -99,8 +99,8 @@ Interfaces for:
@end itemize
@item
-Magit-like popup interface for all Emacs-Guix @kbd{M-x} commands and
-Guix shell commands (@pxref{Popup Interface}).
+Keyboard-driven magit-like menu for all Emacs-Guix @kbd{M-x} and Guix
+shell commands (@pxref{Keyboard-driven Menu}).
@item
Modes to view logs of package builds (@pxref{Build Log Mode}).
@@ -185,10 +185,9 @@ features as without Guix.
interfaces (to display packages, generations, licenses, etc.).
@item
-@uref{https://github.com/magit/magit-popup, magit-popup library}. You
-already have this library if you use Magit 2.1.0 or later. This
-library is required only for @kbd{M-x@tie{}guix} command (@pxref{Popup
-Interface}).
+@uref{https://github.com/magit/transient, transient library}. This
+library is required only for @kbd{M-x@tie{}guix} command
+(@pxref{Keyboard-driven Menu}).
@item
@uref{https://github.com/Fanael/edit-indirect, edit-indirect library},
@@ -204,7 +203,7 @@ list of packages (@pxref{Package Keys}).
@end itemize
To sum up, most likely, you'll need all the above dependencies except
-maybe @code{magit-popup}, @code{edit-indirect} and @code{build-farm}.
+maybe @code{transient}, @code{edit-indirect} and @code{build-farm}.
@node Using from Git
@section Using from Git
@@ -1058,24 +1057,24 @@ Open @file{@dots{}/guix/licenses.scm} and move to the specified license.
@end table
@c ----------------------------------------------------------------
-@node Popup Interface
-@chapter Popup Interface
+@node Keybord-driven Menu
+@chapter Keybord-driven Menu
-If you ever used Magit, you know what ``popup interface'' is
-(@pxref{Top,,, magit-popup, Magit-Popup User Manual}). Even if you are
-not acquainted with Magit, there should be no worries as it is very
-intuitive.
+Transient is the library used to implement keybord-driven ``menus'' like
+in Magit (@pxref{Top,,, transient, Transient User Manual}). Even if you
+are not acquainted with Magit, this interface it is very intuitive.
@findex guix
-So, @kbd{M-x@tie{}guix} command provides a top-level popup interface
-for almost all the available Emacs-Guix commands. It has 2 advantages
-comparing with calling @kbd{M-x@tie{}guix-@dots{}} commands directly:
+So, @kbd{M-x@tie{}guix} command provides a top-level keyboard-driven
+menu for almost all the available Emacs-Guix commands. It has 2
+advantages comparing with calling @kbd{M-x@tie{}guix-@dots{}} commands
+directly:
@itemize
@item
There is no need to remember the names of Emacs-Guix commands, as you
-can always find them in @kbd{M-x@tie{}guix} and its sub-popups.
+can always find them in @kbd{M-x@tie{}guix} and its suffix transients.
@item
It is faster (well, if you know what you are going to call), as it may
@@ -1092,17 +1091,17 @@ easy accessible key combination, for example, to @kbd{@key{super}-g}:
(global-set-key (kbd "s-g") 'guix)
@end example
-@node Guix Popup Interface
-@section Guix Popup Interface
+@node Guix Keyboard-driven Menu
+@section Guix Keyboard-driven Menu
@findex guix-command
-There is one rather special sub-popup in @kbd{M-x@tie{}guix}. It is
-bind to @kbd{c} by default, and you can call it separately with
-@kbd{M-x@tie{}guix-command}. It is a popup interface for
-@code{guix@tie{}@dots{}} shell commands. It is probably not very
+There is one rather special transient suffix in @kbd{M-x@tie{}guix}. It
+is bind to @kbd{c} by default, and you can call it separately with
+@kbd{M-x@tie{}guix-command}. It is a keyboard-driven, magit-like menu
+for @code{guix@tie{}@dots{}} shell commands. It is probably not very
useful, as it provides all the options and flags for all the shell
-actions and subcommands, so it may be confusing to see them all at
-once. Nevertheless, a description of this thing follows.
+actions and subcommands, so it may be confusing to see them all at once.
+Nevertheless, a description of this thing follows.
When you select an option, you'll be prompted for a value in the
minibuffer. Many values have completions, so don't hesitate to press
diff --git a/doc/htmlxref.cnf b/doc/htmlxref.cnf
index d547107..b42ac28 100644
--- a/doc/htmlxref.cnf
+++ b/doc/htmlxref.cnf
@@ -4,9 +4,9 @@
# manuals in the generated HTML pages (created by "make manual"
# command). See (info "(texinfo) HTML Xref Configuration") for details.
-MAGIT_POPUP = https://magit.vc/manual/magit-popup
-magit-popup mono ${MAGIT_POPUP}
-magit-popup node ${MAGIT_POPUP}/
+TRANSIENT = https://magit.vc/manual/transient
+transient mono ${TRANSIENT}
+transient node ${TRANSIENT}/
GEISER = http://www.nongnu.org/geiser
geiser mono ${GEISER}
diff --git a/elisp/guix-command.el b/elisp/guix-command.el
index cbfc0fa..affda4e 100644
--- a/elisp/guix-command.el
+++ b/elisp/guix-command.el
@@ -1,4 +1,4 @@
-;;; guix-command.el --- Popup interface for guix shell commands -*- lexical-binding: t -*-
+;;; guix-command.el --- Transient interface for guix shell commands -*- lexical-binding: t -*-
;; Copyright © 2015–2020 Alex Kost <alezost@gmail.com>
@@ -19,16 +19,16 @@
;;; Commentary:
-;; This file provides a magit-like popup interface for guix shell
-;; commands. You can run a selected command in *shell* buffer, in Guix
-;; REPL, or simply copy it into `kill-ring'.
+;; This file provides a transient interface for guix shell commands.
+;; You can run a selected command in *shell* buffer, in Guix REPL, or
+;; simply copy it into `kill-ring'.
;;
;; The entry point is "M-x guix-command". When it is called the first
;; time, "guix --help" output is parsed and `guix-COMMAND-action'
;; functions are generated for each available guix COMMAND. Then a
;; window with these commands is popped up. When a particular COMMAND
;; is called, "guix COMMAND --help" output is parsed, and a user get a
-;; new popup window with available options for this command and so on.
+;; new transient window with available options for this command and so on.
;; To avoid hard-coding all guix options, actions, etc., as much data is
;; taken from "guix ... --help" outputs as possible. But this data is
@@ -40,7 +40,7 @@
;; structures.
;; Only "M-x guix-command" is available after this file is loaded. The
-;; rest commands/actions/popups are generated on the fly only when they
+;; rest commands/actions/transients are generated on the fly only when they
;; are needed (that's why there is a couple of `eval'-s in this file).
;; COMMANDS argument is used by many functions in this file. It means a
@@ -48,7 +48,7 @@
;; ("import" "gnu"). The empty list stands for the plain "guix" without
;; subcommands.
-;; All actions in popup windows are divided into 2 groups:
+;; All actions in transient windows are divided into 2 groups:
;;
;; - 'Popup' actions - used to pop up another window. For example, every
;; action in the 'guix' or 'guix import' window is a popup action. They
@@ -56,13 +56,13 @@
;;
;; - 'Execute' actions - used to do something with the command line (to
;; run a command in Guix REPL or to copy it into kill-ring) constructed
-;; with the current popup. They are defined by
+;; with the current transient. They are defined by
;; `guix-command-define-execute-action' macro.
;;; Code:
(require 'cl-lib)
-(require 'magit-popup)
+(require 'transient)
(require 'bui-utils)
(require 'guix nil t)
(require 'guix-utils)
@@ -74,7 +74,7 @@
(require 'guix-external)
(defgroup guix-commands nil
- "Settings for guix popup windows."
+ "Settings for guix transient windows."
:group 'guix)
(defvar guix-command-complex-with-shared-arguments
@@ -484,10 +484,10 @@ to be modified."
argument))
(defun guix-command-improve-arguments (arguments commands)
- "Return ARGUMENTS for 'guix COMMANDS ...' modified for popup interface."
+ "Return ARGUMENTS for 'guix COMMANDS ...' modified for transient interface."
(let ((improvers (cons 'guix-command-improve-common-argument
(bui-assoc-value guix-command-argument-improvers
- commands))))
+ commands))))
(mapcar (lambda (argument)
(guix-command-improve-argument argument improvers))
arguments)))
@@ -592,7 +592,7 @@ commands.")
"Return additional arguments for COMMANDS."
(let ((rest-arg (guix-command-rest-argument commands)))
(append (bui-assoc-value guix-command-additional-arguments
- commands)
+ commands)
(and rest-arg (list rest-arg)))))
;; Ideally, only `guix-command-all-arguments' function should exist with
@@ -611,7 +611,7 @@ commands.")
(defun guix-command-all-arguments (&optional commands)
;; Note: `guix-command-arguments' name cannot be used because function
- ;; with this name is generated by `magit-define-popup'.
+ ;; with this name is generated by `transient-define-prefix'.
"Return list of arguments for 'guix COMMANDS ...'."
(let ((command (car commands)))
(if (member command
@@ -634,28 +634,25 @@ commands.")
(guix-command--all-arguments-memoize (list command))))
(guix-command--all-arguments commands))))
-(defun guix-command-switch->popup-switch (switch)
- "Return popup switch from command SWITCH argument."
- (list (guix-command-argument-char switch)
+(defun guix-command-switch->transient-switch (switch)
+ "Return transient switch from command SWITCH argument."
+ (list (format "-%c" (guix-command-argument-char switch))
+ (guix-command-argument-name switch)
(or (guix-command-argument-doc switch)
- "Unknown")
- (guix-command-argument-name switch)))
+ "Unknown")))
-(defun guix-command-option->popup-option (option)
- "Return popup option from command OPTION argument."
- (list (guix-command-argument-char option)
+(defun guix-command-option->transient-option (option)
+ "Return transient option from command OPTION argument."
+ (list (format "-%c" (guix-command-argument-char option))
+ (guix-command-argument-name option)
(or (guix-command-argument-doc option)
"Unknown")
- (let ((name (guix-command-argument-name option)))
- (if (string-match-p " \\'" name) ; ends with space
- name
- (concat name "=")))
(or (guix-command-argument-fun option)
'read-from-minibuffer)))
-(defun guix-command-action->popup-action (action)
- "Return popup action from command ACTION argument."
- (list (guix-command-argument-char action)
+(defun guix-command-action->transient-suffix (action)
+ "Return transient suffix from command ACTION argument."
+ (list (format "-%c" (guix-command-argument-char action))
(or (guix-command-argument-doc action)
(guix-command-argument-name action)
"Unknown")
@@ -683,8 +680,8 @@ commands.")
"Return actions from ARGUMENTS."
(cl-remove-if-not #'guix-command-argument-action? arguments))
-
-;;; Post processing popup arguments
+
+;;; Post processing transient arguments
(defvar guix-command-post-processors
'(("environment"
@@ -698,7 +695,7 @@ commands.")
("system"
guix-command-post-process-rest-single))
"Alist of guix commands and functions for post-processing
-a list of arguments returned from popup interface.
+a list of arguments returned from transient interface.
Each function is called on the returned arguments in turn.")
(defvar guix-command-rest-arg-regexp
@@ -760,13 +757,13 @@ Leave '--' string as a separate argument."
:split? t))
(defun guix-command-post-process-package-args (args)
- "Adjust popup ARGS for 'guix package' command."
+ "Adjust transient ARGS for 'guix package' command."
(guix-command-post-process-matching-args
args (rx string-start (or "--install " "--remove ") (+ any))
:split? t))
(defun guix-command-post-process-environment-packages (args)
- "Adjust popup ARGS for specified packages of 'guix environment'
+ "Adjust transient ARGS for specified packages of 'guix environment'
command."
(guix-command-post-process-matching-args
args (rx string-start "++packages " (group (+ any)))
@@ -774,14 +771,14 @@ command."
:split? t))
(defun guix-command-post-process-environment-ad-hoc (args)
- "Adjust popup ARGS for '--ad-hoc' argument of 'guix environment'
+ "Adjust transient ARGS for '--ad-hoc' argument of 'guix environment'
command."
(guix-command-post-process-matching-args
args (rx string-start "--ad-hoc " (+ any))
:split? t))
(defun guix-command-post-process-args (commands args)
- "Adjust popup ARGS for guix COMMANDS."
+ "Adjust transient ARGS for guix COMMANDS."
(let* ((command (car commands))
(processors
(append (bui-assoc-value guix-command-post-processors commands)
@@ -931,32 +928,31 @@ open the log file(s)."
;;; Generating popups, actions, etc.
(defmacro guix-command-define-popup-action (name &optional commands)
- "Define NAME function to generate (if needed) and run popup for COMMANDS."
+ "Define NAME function to generate (if needed) and run transient for COMMANDS."
(declare (indent 1) (debug t))
- (let* ((popup-fun (guix-command-symbol `(,@commands "popup")))
+ (let* ((prefix-fun (guix-command-symbol `(,@commands "prefix")))
(doc (format "Call `%s' (generate it if needed)."
- popup-fun)))
+ prefix-fun)))
`(defun ,name (&optional arg)
,doc
(interactive "P")
- (unless (fboundp ',popup-fun)
- (guix-command-generate-popup ',popup-fun ',commands))
- (,popup-fun arg))))
+ (unless (fboundp ',prefix-fun)
+ (guix-command-generate-prefix ',prefix-fun ',commands))
+ (,prefix-fun))))
(defmacro guix-command-define-execute-action (name executor
&optional commands)
"Define NAME function to execute the current action for guix COMMANDS.
EXECUTOR function is called with the current command line arguments."
(declare (indent 1) (debug t))
- (let* ((arguments-fun (guix-command-symbol `(,@commands "arguments")))
- (doc (format "Call `%s' with the current popup arguments."
+ (let* ((doc (format "Call `%s' with the current transient arguments."
executor)))
`(defun ,name (&rest args)
,doc
- (interactive (,arguments-fun))
+ (interactive)
(,executor (append ',commands
(guix-command-post-process-args
- ',commands args))))))
+ ',commands (transient-args (transient-current-command))))))))
(defun guix-command-generate-popup-actions (actions &optional commands)
"Generate 'popup' commands from ACTIONS arguments for guix COMMANDS."
@@ -977,11 +973,11 @@ EXECUTOR function is called with the current command line arguments."
commands (guix-command-argument-name action))
,commands))))))
-(defun guix-command-generate-popup (name &optional commands)
- "Define NAME popup with 'guix COMMANDS ...' interface."
+(defun guix-command-generate-prefix (name &optional commands)
+ "Define NAME prefix with 'guix COMMANDS ...' interface."
(let* ((command (car commands))
(man-page (concat "guix" (and command (concat "-" command))))
- (doc (format "Popup window for '%s' command."
+ (doc (format "Transient for '%s' command."
(guix-concat-strings (cons "guix" commands)
" ")))
(args (guix-command-all-arguments commands))
@@ -998,18 +994,22 @@ EXECUTOR function is called with the current command line arguments."
(guix-command-generate-popup-actions popup-actions commands)
(guix-command-generate-execute-actions execute-actions commands))
(eval
- `(magit-define-popup ,name
+ `(transient-define-prefix ,name ()
,doc
- 'guix-commands
:man-page ,man-page
- :switches ',(mapcar #'guix-command-switch->popup-switch switches)
- :options ',(mapcar #'guix-command-option->popup-option options)
- :actions ',(mapcar #'guix-command-action->popup-action actions)
- :max-a
This message was truncated. Download the full message here.
Nicolas Graves wrote 3 weeks ago
[PATCH 5/5] Update NEWS
(address . 76699@debbugs.gnu.org)(name . Nicolas Graves)(address . ngraves@ngraves.fr)
20250303020932.4194-5-ngraves@ngraves.fr
---
NEWS | 10 ++++++++++
1 file changed, 10 insertions(+)

Toggle diff (22 lines)
diff --git a/NEWS b/NEWS
index b4904f0..c971130 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,15 @@
-*- mode: org -*-
+* Changes in 0.5.3 (since 0.5.2)
+
+Minor user-visible changes, no functionality addition, mostly refreshing changes:
+
+- refreshing most doctrings to pass on emacs@29 flymake standards
+- remove dependency on the dash library, introduce the lighter llama library in order to replace the compact syntax for short lambdas
+- replace outdated emacs-popup by transient library
+- allow the use of the repository as a channel
+- refresh installation / development tools
+
* Changes in 0.5.2 (since 0.5.1.1)
** User visible changes
--
2.48.1
Nicolas Graves wrote 3 weeks ago
[PATCH 4/5] Use a development channel instead of guix.scm
(address . 76699@debbugs.gnu.org)(name . Nicolas Graves)(address . ngraves@ngraves.fr)
20250303020932.4194-4-ngraves@ngraves.fr
---
.guix-channel | 3 +
guix.scm => channel/emacs-guix-channel.scm | 69 ++++++--------
channel/emacs-guix-channel.scm.next | 104 +++++++++++++++++++++
3 files changed, 137 insertions(+), 39 deletions(-)
create mode 100644 .guix-channel
rename guix.scm => channel/emacs-guix-channel.scm (50%)
create mode 100644 channel/emacs-guix-channel.scm.next

Toggle diff (238 lines)
diff --git a/.guix-channel b/.guix-channel
new file mode 100644
index 0000000..bb2ac66
--- /dev/null
+++ b/.guix-channel
@@ -0,0 +1,3 @@
+(channel
+ (version 0)
+ (directory "channel"))
diff --git a/guix.scm b/channel/emacs-guix-channel.scm
similarity index 50%
rename from guix.scm
rename to channel/emacs-guix-channel.scm
index d35b0ba..ea8a6e7 100644
--- a/guix.scm
+++ b/channel/emacs-guix-channel.scm
@@ -2,6 +2,7 @@
;; Copyright © 2017 Alex Kost <alezost@gmail.com>
;; Copyright © 2019 Oleg Pykhalov <go.wigust@gmail.com>
+;; Copyright © 2025 Nicolas Graves <ngraves@ngraves.fr>
;; This file is part of Emacs-Guix.
@@ -21,72 +22,62 @@
;;; Commentary:
;; This file contains Guix package for development version of
-;; Emacs-Guix. To build or install, run:
+;; Emacs-Guix. To build it, you need guile-git in your profile.
+;; Then, in the parent directory, run or install:
;;
-;; guix build --file=guix.scm
-;; guix package --install-from-file=guix.scm
+;; guix build -L channel emacs-guix-devel
+;; guix install -L channel emacs-guix-devel
;; The main purpose of this file though is to make a development
;; environment for building Emacs-Guix:
;;
-;; guix environment --pure --load=guix.scm
+;; guix shell -L channel -D --pure emacs-guix-devel
;; ./autogen.sh
;; ./configure
;; make
;;; Code:
+(define-module (emacs-guix-channel))
+
(use-modules
+ (git)
(ice-9 popen)
(ice-9 rdelim)
(guix build utils)
(guix gexp)
(guix git-download)
(guix packages)
+ (guix utils)
(gnu packages autotools)
(gnu packages emacs)
(gnu packages emacs-xyz)
+ (gnu packages guile-xyz)
(gnu packages pkg-config)
(gnu packages texinfo))
-(define %source-dir (dirname (current-filename)))
-
-(define (git-output . args)
- "Execute 'git ARGS ...' command and return its output without trailing
-newspace."
- (with-directory-excursion %source-dir
- (let* ((port (apply open-pipe* OPEN_READ "git" args))
- (output (read-string port)))
- (close-pipe port)
- (string-trim-right output #\newline))))
-
-(define (current-commit)
- (git-output "log" "-n" "1" "--pretty=format:%H"))
-
-(define emacs-guix-devel
- (let ((commit (current-commit)))
+(define-public emacs-guix/devel
+ (let* ((source-dir (dirname (dirname (current-filename))))
+ (repo (repository-open source-dir))
+ (commit (oid->string (object-id (revparse-single repo "HEAD")))))
(package
(inherit emacs-guix)
- (version (string-append (package-version emacs-guix)
- "-" (string-take commit 7)))
- (source (local-file %source-dir
+ (name "emacs-guix-devel")
+ (version (string-append
+ (string-drop-right (package-version emacs-guix) 7)
+ (string-take commit 7)))
+ (source (local-file source-dir
#:recursive? #t
- #:select? (git-predicate %source-dir)))
+ #:select? (git-predicate source-dir)))
(arguments
- (append (package-arguments emacs-guix)
- '(#:phases
- (modify-phases %standard-phases
- (add-after 'unpack 'autogen
- (lambda _ (zero? (system* "sh" "autogen.sh"))))))))
- (native-inputs
- `(("pkg-config" ,pkg-config)
- ;; 'emacs-minimal' does not find Emacs packages (this is for
- ;; "guix environment").
- ("emacs" ,emacs-no-x)
- ("autoconf" ,autoconf)
- ("automake" ,automake)
- ("texinfo" ,texinfo))))))
-
-emacs-guix-devel
+ (substitute-keyword-arguments (package-arguments emacs-guix)
+ ((#:phases phases)
+ #~(modify-phases #$phases
+ (add-after 'unpack 'autogen
+ (lambda _ (zero? (system* "sh" "autogen.sh"))))))))
+ (propagated-inputs
+ (modify-inputs (package-propagated-inputs emacs-guix)
+ (replace "emacs-dash" emacs-llama)
+ (replace "emacs-magit-popup" emacs-transient))))))
;;; guix.scm ends here
diff --git a/channel/emacs-guix-channel.scm.next b/channel/emacs-guix-channel.scm.next
new file mode 100644
index 0000000..58a2a44
--- /dev/null
+++ b/channel/emacs-guix-channel.scm.next
@@ -0,0 +1,104 @@
+;;; guix.scm --- Guix package for Emacs-Guix
+
+;; Copyright © 2017 Alex Kost <alezost@gmail.com>
+;; Copyright © 2019 Oleg Pykhalov <go.wigust@gmail.com>
+;; Copyright © 2025 Nicolas Graves <ngraves@ngraves.fr>
+
+;; This file is part of Emacs-Guix.
+
+;; Emacs-Guix is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+;;
+;; Emacs-Guix is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+;;
+;; You should have received a copy of the GNU General Public License
+;; along with Emacs-Guix. If not, see <http://www.gnu.org/licenses/>.
+
+;;; Commentary:
+
+;; This file contains Guix package for development version of
+;; Emacs-Guix. To build or install, run:
+;;
+;; guix build --file=guix.scm
+;; guix package --install-from-file=guix.scm
+
+;; The main purpose of this file though is to make a development
+;; environment for building Emacs-Guix:
+;;
+;; guix environment --pure --load=guix.scm
+;; ./autogen.sh
+;; ./configure
+;; make
+
+;;; Code:
+
+(define-module (emacs-guix-channel))
+
+(use-modules
+ (git)
+ (ice-9 match)
+ (ice-9 popen)
+ (ice-9 rdelim)
+ (guix build utils)
+ (guix gexp)
+ (guix git-download)
+ (guix packages)
+ (guix profiles)
+ (gnu packages autotools)
+ (gnu packages emacs)
+ (gnu packages emacs-xyz)
+ (rde packages emacs-xyz)
+ (gnu packages guile)
+ (gnu packages guile-xyz)
+ (rde packages guile-xyz)
+ (gnu packages package-management)
+ (gnu packages pkg-config)
+ (gnu packages terminals)
+ (gnu packages texinfo))
+
+(define guix-with-guile-next
+ ((package-input-rewriting/spec `(("guile" . ,(const guile-next)))) guix))
+
+(define emacs-guix/devel
+ (let* ((source-dir (dirname (dirname (current-filename))))
+ (repo (repository-open source-dir))
+ (commit (oid->string
+ (object-id (revparse-single repo "HEAD")))))
+ (package
+ (inherit emacs-guix)
+ (name "emacs-guix-arei")
+ (version (string-append
+ (string-drop-right (package-version emacs-guix) 7)
+ (string-take commit 7)))
+ (source (local-file source-dir
+ #:recursive? #t
+ #:select? (git-predicate source-dir)))
+ ;; (arguments
+ ;; (append (package-arguments emacs-guix)
+ ;; '(#:phases
+ ;; (modify-phases %standard-phases
+ ;; (add-after 'unpack 'autogen
+ ;; (lambda _ (zero? (system* "sh" "autogen.sh"))))))))
+ (inputs
+ (modify-inputs (package-inputs emacs-guix)
+ (replace "guile" guile-next)
+ (append guile-ares-rs-latest)
+ (append foot)))
+ (propagated-inputs
+ (modify-inputs (package-propagated-inputs emacs-guix)
+ (append emacs-arei-latest))))))
+
+(match (cdr (command-line))
+ (("build" . rest) emacs-guix/devel)
+ ;; (("shell" "-D" . rest) )
+ ;; (("shell" . rest) (specifications->manifest (list "emacs-guix/devel")))
+ (otherwise (package->development-manifest emacs-guix/devel)
+ ;; (error (format #f "Unable to handle ~a!" otherwise))
+ ))
+
+;;; guix.scm ends here
--
2.48.1
Ludovic Courtès wrote 2 weeks ago
(name . Nicolas Graves)(address . ngraves@ngraves.fr)(address . 76699@debbugs.gnu.org)
87ldtfsbqo.fsf@gnu.org
Hi Nicolas,

Nicolas Graves <ngraves@ngraves.fr> skribis:

Toggle quote (27 lines)
> ---
> .guix-channel | 3 +
> guix.scm => channel/emacs-guix-channel.scm | 69 ++++++--------
> channel/emacs-guix-channel.scm.next | 104 +++++++++++++++++++++
> 3 files changed, 137 insertions(+), 39 deletions(-)
> create mode 100644 .guix-channel
> rename guix.scm => channel/emacs-guix-channel.scm (50%)
> create mode 100644 channel/emacs-guix-channel.scm.next
>
> diff --git a/.guix-channel b/.guix-channel
> new file mode 100644
> index 0000000..bb2ac66
> --- /dev/null
> +++ b/.guix-channel
> @@ -0,0 +1,3 @@
> +(channel
> + (version 0)
> + (directory "channel"))
> diff --git a/guix.scm b/channel/emacs-guix-channel.scm
> similarity index 50%
> rename from guix.scm
> rename to channel/emacs-guix-channel.scm
> index d35b0ba..ea8a6e7 100644
> --- a/guix.scm
> +++ b/channel/emacs-guix-channel.scm
> @@ -2,6 +2,7 @@

I’d suggest:

1. Renaming ‘channel’ to ‘.guix/modules’;
2. Making ‘guix.scm’ a symlink to
‘.guix/modules/emacs-guix-packages.scm’.

This would follow the conventions described in the cookbook (info
"(guix-cookbook) Software Development").

Toggle quote (7 lines)
> +(define-module (emacs-guix-channel))
> +
> (use-modules
> + (git)
> (ice-9 popen)
> (ice-9 rdelim)

While you’re at it, I’d suggest grouping things together:

(define-module (emacs-guix-packages)
#:use-module (git)
#:use-module …)

Toggle quote (2 lines)
> +++ b/channel/emacs-guix-channel.scm.next

What is this supposed to be? I suspect it’s unnecessary. :-)

Thanks,
Ludo’.
Ludovic Courtès wrote 2 weeks ago
Re: [bug#76699] [PATCH emacs-guix 0/4] Refresh package emacs-guix
(name . Nicolas Graves)(address . ngraves@ngraves.fr)(address . 76699@debbugs.gnu.org)
87jz8zsbo2.fsf@gnu.org
Hello,

Nicolas Graves <ngraves@ngraves.fr> skribis:

Toggle quote (2 lines)
> This is a series of refreshing commits for emacs-guix.

Yay!

Toggle quote (4 lines)
> This is done in an effort to port emacs-guix to
> guile-ares-rs/emacs-arei backend, currently in progress here :
> https://git.sr.ht/~ngraves/emacs-guix

I remain fond of Geiser so I’m skeptical of this change. Perhaps you
could explain a bit why you think it’s worthwhile?

Toggle quote (8 lines)
> This is still a WIP, I'd still like to replace old references to
> guix-environment by references to guix shell at least. I'm not able
> to test all changes, since guix-command seems to be broken (before
> this patch series I mean).
>
> Thus, I invite users of emacs-guix to try that series and report any
> bug that could have been caused by it.

I haven’t tried it yet but it LGTM, except for patch #4.

Ludo’.
Nicolas Graves wrote 2 weeks ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 76699@debbugs.gnu.org)
87o6yb2jht.fsf@ngraves.fr
On 2025-03-08 17:57, Ludovic Courtès wrote:

Toggle quote (15 lines)
> Hello,
>
> Nicolas Graves <ngraves@ngraves.fr> skribis:
>
>> This is a series of refreshing commits for emacs-guix.
>
> Yay!
>
>> This is done in an effort to port emacs-guix to
>> guile-ares-rs/emacs-arei backend, currently in progress here :
>> https://git.sr.ht/~ngraves/emacs-guix
>
> I remain fond of Geiser so I’m skeptical of this change. Perhaps you
> could explain a bit why you think it’s worthwhile?

Both could exist together if we remain coordinated (hence first the
effort to improve, before efforts to port ;), "port" here is not
necessarily meant to replace.

I'm not qualified enough myself to judge, let's say that I've been sold
to ares/arei by the asynchronous/fluency/protocol guarantees. Andrew
Tropin's talk on EmacsConf 2023 elaborate more on why the project was
started in the first place.


I've found it convenient to write and test scheme (a bit less finished
on the user's side -- you still have to start the server manually) ; but
overall I find it quite pleasant to use, simply write and evaluate the
code I'm writing without having to write to copy/paste.

What I would want such a package to do is also to have convenient
features like:
- guix packages recognition while developping (for embark actions)
- guix-lint/flymake integration + embark action
- guix-style embark action

I see this kind of things possible with ares ; I don't know geiser
enough to know if it's possible / convenient / how to tackle them
properly.

Toggle quote (2 lines)
> I haven’t tried it yet but it LGTM, except for patch #4.

Will look into that, thanks!

By the way, I would like to get rid of emacs-bui too, I think it adds a
lot of complexity / it is one of the reasons emacs-guix is hard to
maintain. I was thinking about

- rewriting the completing-read part // replacing the list mode
functionality with a completing-read that would list synopses when
present with packages like vertico/marginalia (so no more dedicated
mode, just a more carefully written completing-read) ;

- replacing the guix-ui mode with its proper transient (on *Guix info*,
hitting `h` almost spawns a transient-like menu, so it might be more
maintainable with transient itself, and with a popping transient,
there's no need for buttons), and probably a beautified read-only
rec-mode like interface ; if we manage to inject recutils from scheme,
it might be a lot less code to maintain in emacs-guix.

IMHO, both would make it easier to maintain and extend the package, at the
cost of a little less "polish". Sometimes less is more!

--
Best regards,
Nicolas Graves
Ludovic Courtès wrote 2 weeks ago
(name . Nicolas Graves)(address . ngraves@ngraves.fr)(address . 76699@debbugs.gnu.org)
87zfhtq5ia.fsf@gnu.org
Hi,

Nicolas Graves <ngraves@ngraves.fr> skribis:

Toggle quote (14 lines)
>> I remain fond of Geiser so I’m skeptical of this change. Perhaps you
>> could explain a bit why you think it’s worthwhile?
>
> Both could exist together if we remain coordinated (hence first the
> effort to improve, before efforts to port ;), "port" here is not
> necessarily meant to replace.
>
> I'm not qualified enough myself to judge, let's say that I've been sold
> to ares/arei by the asynchronous/fluency/protocol guarantees. Andrew
> Tropin's talk on EmacsConf 2023 elaborate more on why the project was
> started in the first place.
>
> https://emacsconf.org/2023/talks/scheme/

OK, I should take a look.

Toggle quote (5 lines)
> I've found it convenient to write and test scheme (a bit less finished
> on the user's side -- you still have to start the server manually) ; but
> overall I find it quite pleasant to use, simply write and evaluate the
> code I'm writing without having to write to copy/paste.

Agreed, same with Geiser and other such tools.

Toggle quote (6 lines)
> What I would want such a package to do is also to have convenient
> features like:
> - guix packages recognition while developping (for embark actions)
> - guix-lint/flymake integration + embark action
> - guix-style embark action

Would be nice!

Toggle quote (4 lines)
> I see this kind of things possible with ares ; I don't know geiser
> enough to know if it's possible / convenient / how to tackle them
> properly.

Geiser essentially talks to a running Guile REPL in a request/response
style. Its downside is that it’s synchronous, and that’s something ares
probably improves on, but for the rest it’s really good.

Toggle quote (9 lines)
> By the way, I would like to get rid of emacs-bui too, I think it adds a
> lot of complexity / it is one of the reasons emacs-guix is hard to
> maintain. I was thinking about
>
> - rewriting the completing-read part // replacing the list mode
> functionality with a completing-read that would list synopses when
> present with packages like vertico/marginalia (so no more dedicated
> mode, just a more carefully written completing-read) ;

I’m not qualified enough to judge, but removing code can be nice. :-)

Toggle quote (7 lines)
> - replacing the guix-ui mode with its proper transient (on *Guix info*,
> hitting `h` almost spawns a transient-like menu, so it might be more
> maintainable with transient itself, and with a popping transient,
> there's no need for buttons), and probably a beautified read-only
> rec-mode like interface ; if we manage to inject recutils from scheme,
> it might be a lot less code to maintain in emacs-guix.

I’m not sure I’d rely on ‘rec-mode’ for this (I think the current
interface is more pleasant than a raw recutils record as view with
rec-mode, and it’s interactive too), but I don’t know.

Thanks,
Ludo’.
Nicolas Graves wrote 1 weeks ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 76699@debbugs.gnu.org)
874izvbvg9.fsf@ngraves.fr
Would you rather create an emacs-guix-next package and call users to try
it, or rather just make this update?

I ask because the new development channel should adapt to how we'll
include that in guix (is modify-inputs necessary or not ?)

Nicolas

--
Best regards,
Nicolas Graves
Nicolas Graves wrote 1 weeks ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 76699@debbugs.gnu.org)
871puzbv2v.fsf@ngraves.fr
On 2025-03-09 22:05, Ludovic Courtès wrote:
Toggle quote (12 lines)
>
>> - replacing the guix-ui mode with its proper transient (on *Guix info*,
>> hitting `h` almost spawns a transient-like menu, so it might be more
>> maintainable with transient itself, and with a popping transient,
>> there's no need for buttons), and probably a beautified read-only
>> rec-mode like interface ; if we manage to inject recutils from scheme,
>> it might be a lot less code to maintain in emacs-guix.
>
> I’m not sure I’d rely on ‘rec-mode’ for this (I think the current
> interface is more pleasant than a raw recutils record as view with
> rec-mode, and it’s interactive too), but I don’t know.

My point here is that I would prefer a new transient menu in this *Guix
package info* instead of sparse buttons, since it's already based on
transient. I agree the view is more pleasant, but I think it's quite
likely that the emacs-bui package will not be developped
again. `rec-mode` is probably too rough, I'll try and find an
intermediary alternative.

--
Best regards,
Nicolas Graves
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 76699@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 76699
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help