aboutsummaryrefslogtreecommitdiff
path: root/emacs/guix-main.scm
diff options
context:
space:
mode:
authorAlex Kost <alezost@gmail.com>2016-01-04 22:59:04 +0300
committerAlex Kost <alezost@gmail.com>2016-01-16 13:02:21 +0300
commit54c3c284d7f319d6db7c665c612fdbeefe81ae5f (patch)
treeda969d795667472a21ea87af0ea36cb86e11935c /emacs/guix-main.scm
parent2df17bd0eeed1e29e64cf21ecec61413af19ba65 (diff)
downloadgnu-guix-54c3c284d7f319d6db7c665c612fdbeefe81ae5f.tar
gnu-guix-54c3c284d7f319d6db7c665c612fdbeefe81ae5f.tar.gz
emacs: Replace 'generation-diff' search with 'profile-diff'.
* emacs/guix-main.scm (generation-package-specifications): Rename to... (profile-package-specifications): ... this. Take a single 'profile' argument. (generation-difference): Rename to... (profile-difference): ... this. Take profiles as arguments. (package/output-sexps): Adjust accordingly. * emacs/guix-ui-generation.el (guix-generation-list-profiles-to-compare): New procedure. (guix-generation-list-show-added-packages) (guix-generation-list-show-removed-packages): Use it. * emacs/guix-messages.el (guix-messages): Replace 'generation-diff' with 'profile-diff'. (guix-message-outputs-by-diff): Adjust accordingly.
Diffstat (limited to 'emacs/guix-main.scm')
-rw-r--r--emacs/guix-main.scm23
1 files changed, 11 insertions, 12 deletions
diff --git a/emacs/guix-main.scm b/emacs/guix-main.scm
index 5460c9686e..dfa9cba8e4 100644
--- a/emacs/guix-main.scm
+++ b/emacs/guix-main.scm
@@ -137,10 +137,9 @@ return two values: name and version. For example, for SPEC
(define (manifest-entries->package-specifications entries)
(map manifest-entry->package-specification entries))
-(define (generation-package-specifications profile number)
- "Return a list of package specifications for generation NUMBER."
- (let ((manifest (profile-manifest
- (generation-file-name profile number))))
+(define (profile-package-specifications profile)
+ "Return a list of package specifications for PROFILE."
+ (let ((manifest (profile-manifest profile)))
(manifest-entries->package-specifications
(manifest-entries manifest))))
@@ -153,11 +152,11 @@ Each element of the list is a list of the package specification and its path."
(manifest-entry-item entry)))
(manifest-entries manifest))))
-(define (generation-difference profile number1 number2)
- "Return a list of package specifications for outputs installed in generation
-NUMBER1 and not installed in generation NUMBER2."
- (let ((specs1 (generation-package-specifications profile number1))
- (specs2 (generation-package-specifications profile number2)))
+(define (profile-difference profile1 profile2)
+ "Return a list of package specifications for outputs installed in PROFILE1
+and not installed in PROFILE2."
+ (let ((specs1 (profile-package-specifications profile1))
+ (specs2 (profile-package-specifications profile2)))
(lset-difference string=? specs1 specs2)))
(define (manifest-entries->hash-table entries)
@@ -698,11 +697,11 @@ See 'entry-sexps' for details."
profile))
(manifest (profile-manifest profile))
(patterns (if (and (eq? entry-type 'output)
- (eq? search-type 'generation-diff))
+ (eq? search-type 'profile-diff))
(match search-vals
- ((g1 g2)
+ ((p1 p2)
(map specification->output-pattern
- (generation-difference profile g1 g2)))
+ (profile-difference p1 p2)))
(_ '()))
(apply (patterns-maker entry-type search-type)
manifest search-vals)))