diff options
author | Marius Bakke <mbakke@fastmail.com> | 2017-05-24 22:12:13 +0200 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2017-05-24 22:12:13 +0200 |
commit | 36747eb0dad504686560afba51742f782f7c3646 (patch) | |
tree | 2a35da31146f0a6693fd9cddfc0c514edefe9c99 /guix/scripts/package.scm | |
parent | ffaf5cbd361b6589daac1912aa5a43abea86e52b (diff) | |
parent | 0b7b8fb0456475374de24b6302a6ce3cc5921ed0 (diff) |
Merge branch 'master' into staging
Diffstat (limited to 'guix/scripts/package.scm')
-rw-r--r-- | guix/scripts/package.scm | 38 |
1 files changed, 20 insertions, 18 deletions
diff --git a/guix/scripts/package.scm b/guix/scripts/package.scm index 1f3f49fc6f..f050fad976 100644 --- a/guix/scripts/package.scm +++ b/guix/scripts/package.scm @@ -681,24 +681,26 @@ processed, #f otherwise." (unless (null-list? (cdr numbers)) (display-profile-content-diff profile (car numbers) (cadr numbers)) (diff-profiles profile (cdr numbers)))) - (cond ((not (file-exists? profile)) ; XXX: race condition - (raise (condition (&profile-not-found-error - (profile profile))))) - ((string-null? pattern) - (list-generation display-profile-content - (car (profile-generations profile))) - (diff-profiles profile (profile-generations profile))) - ((matching-generations pattern profile) - => - (lambda (numbers) - (if (null-list? numbers) - (exit 1) - (leave-on-EPIPE - (list-generation display-profile-content (car numbers)) - (diff-profiles profile numbers))))) - (else - (leave (G_ "invalid syntax: ~a~%") - pattern))) + + (leave-on-EPIPE + (cond ((not (file-exists? profile)) ; XXX: race condition + (raise (condition (&profile-not-found-error + (profile profile))))) + ((string-null? pattern) + (list-generation display-profile-content + (car (profile-generations profile))) + (diff-profiles profile (profile-generations profile))) + ((matching-generations pattern profile) + => + (lambda (numbers) + (if (null-list? numbers) + (exit 1) + (begin + (list-generation display-profile-content (car numbers)) + (diff-profiles profile numbers))))) + (else + (leave (G_ "invalid syntax: ~a~%") + pattern)))) #t) (('list-installed regexp) |