From 67cedc4ba69ec90b2d9d94646b861ba6821f342d Mon Sep 17 00:00:00 2001 From: Alex Kost Date: Thu, 7 Jan 2016 23:01:26 +0300 Subject: emacs: Add interface for system generations. * emacs/guix-main.scm (system-generation-boot-parameters) (system-generation-param-alist, system-generation-sexps): New procedures. (entries): Add 'system-generation' entry type. * emacs/guix-messages.el (guix-result-message): Use the same messages for 'generation' and 'system-generation' entry types. * emacs/guix-ui-system-generation.el: New file. * emacs.am (ELFILES): Add it. * doc/emacs.texi (Emacs Commands): Document new commands. * NEWS: Mention new interface. --- doc/emacs.texi | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'doc/emacs.texi') diff --git a/doc/emacs.texi b/doc/emacs.texi index ea340b19fe..b2a3d473ab 100644 --- a/doc/emacs.texi +++ b/doc/emacs.texi @@ -191,6 +191,14 @@ date/time prompt,,, org, The Org Manual}). @end table +Analogously on GuixSD you can also display system generations: + +@table @kbd +@item M-x guix-system-generations +@item M-x guix-last-system-generations +@item M-x guix-system-generations-by-time +@end table + You can also invoke the @command{guix pull} command (@pxref{Invoking guix pull}) from Emacs using: -- cgit v1.2.3 From e119ba900877970325b2158dd6d3c700feaab516 Mon Sep 17 00:00:00 2001 From: Alex Kost Date: Tue, 12 Jan 2016 18:06:32 +0300 Subject: emacs: Rename 'guix-search-by-name' to 'guix-packages-by-name'. * emacs/guix-ui-package.el (guix-search-by-name): Rename to... (guix-packages-by-name): ... this. Complete package name. * doc/emacs.texi (Emacs Commands): Likewise. --- doc/emacs.texi | 2 +- emacs/guix-ui-package.el | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'doc/emacs.texi') diff --git a/doc/emacs.texi b/doc/emacs.texi index b2a3d473ab..7edaedc078 100644 --- a/doc/emacs.texi +++ b/doc/emacs.texi @@ -155,7 +155,7 @@ Display all installed packages. Display obsolete packages (the packages that are installed in a profile but cannot be found among available packages). -@item M-x guix-search-by-name +@item M-x guix-packages-by-name Display package(s) with the specified name. @item M-x guix-search-by-regexp diff --git a/emacs/guix-ui-package.el b/emacs/guix-ui-package.el index 7cf1a7d07f..0696c4b565 100644 --- a/emacs/guix-ui-package.el +++ b/emacs/guix-ui-package.el @@ -912,15 +912,15 @@ See `guix-package-info-type'." "A history of minibuffer prompts.") ;;;###autoload -(defun guix-search-by-name (name &optional profile) - "Search for Guix packages by NAME. +(defun guix-packages-by-name (name &optional profile) + "Display Guix packages with NAME. NAME is a string with name specification. It may optionally contain a version number. Examples: \"guile\", \"guile-2.0.11\". If PROFILE is nil, use `guix-current-profile'. Interactively with prefix, prompt for PROFILE." (interactive - (list (read-string "Package name: " nil 'guix-package-search-history) + (list (guix-read-package-name) (guix-ui-read-profile))) (guix-package-get-display profile 'name name)) -- cgit v1.2.3 From 27a2e483370f9d08b9724a2c82b1fee9b15ce58a Mon Sep 17 00:00:00 2001 From: Alex Kost Date: Tue, 12 Jan 2016 18:10:14 +0300 Subject: emacs: Add 'guix-search-by-name'. * emacs/guix-ui-package.el (guix-search-by-name): New command. * doc/emacs.texi (Emacs Commands): Document it. --- doc/emacs.texi | 5 +++++ emacs/guix-ui-package.el | 11 +++++++++++ 2 files changed, 16 insertions(+) (limited to 'doc/emacs.texi') diff --git a/doc/emacs.texi b/doc/emacs.texi index 7edaedc078..eb470ab4ca 100644 --- a/doc/emacs.texi +++ b/doc/emacs.texi @@ -163,6 +163,11 @@ Search for packages by a specified regexp. By default ``name'', ``synopsis'' and ``description'' of the packages will be searched. This can be changed by modifying @code{guix-package-search-params} variable. +@item M-x guix-search-by-name +Search for packages with names matching a specified regexp. This +command is the same as @code{guix-search-by-regexp}, except only a +package ``name'' is searched. + @end table By default, these commands display each output on a separate line. If diff --git a/emacs/guix-ui-package.el b/emacs/guix-ui-package.el index 0696c4b565..29514527ce 100644 --- a/emacs/guix-ui-package.el +++ b/emacs/guix-ui-package.el @@ -938,6 +938,17 @@ Interactively with prefix, prompt for PROFILE." (guix-package-get-display profile 'regexp regexp (or params guix-package-search-params))) +;;;###autoload +(defun guix-search-by-name (regexp &optional profile) + "Search for Guix packages matching REGEXP in a package name. +If PROFILE is nil, use `guix-current-profile'. +Interactively with prefix, prompt for PROFILE." + (interactive + (list (read-string "Package name by regexp: " + nil 'guix-package-search-history) + (guix-ui-read-profile))) + (guix-search-by-regexp regexp '(name) profile)) + ;;;###autoload (defun guix-installed-packages (&optional profile) "Display information about installed Guix packages. -- cgit v1.2.3