summaryrefslogtreecommitdiff
path: root/guix/scripts/environment.scm
diff options
context:
space:
mode:
author宋文武 <iyzsong@gmail.com>2016-05-08 17:54:46 +0800
committer宋文武 <iyzsong@gmail.com>2016-05-08 17:54:46 +0800
commit6655a74326beb18632b5c8277db39fd02a154007 (patch)
treefed007de99235258098222f04fa1e4853c1d3d60 /guix/scripts/environment.scm
parent4e9d04a80b2d8b1e07f78708dae76b13f3d421f6 (diff)
parent2d4422d5b53276661a68f65b91daa854de88c165 (diff)
Merge branch 'master' into gnome-updates
Diffstat (limited to 'guix/scripts/environment.scm')
-rw-r--r--guix/scripts/environment.scm10
1 files changed, 5 insertions, 5 deletions
diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm
index d4c09ef54c..9ba487d1eb 100644
--- a/guix/scripts/environment.scm
+++ b/guix/scripts/environment.scm
@@ -25,7 +25,6 @@
#:use-module (guix packages)
#:use-module (guix profiles)
#:use-module (guix search-paths)
- #:use-module (guix utils)
#:use-module (guix build utils)
#:use-module (guix monads)
#:use-module ((guix gexp) #:select (lower-inputs))
@@ -499,12 +498,13 @@ Otherwise, return the derivation for the Bash package."
;; The '--' token is used to separate the command to run from the rest of
;; the operands.
- (let-values (((args command) (split args "--")))
+ (let-values (((args command) (break (cut string=? "--" <>) args)))
(let ((opts (parse-command-line args %options (list %default-options)
#:argument-handler handle-argument)))
- (if (null? command)
- opts
- (alist-cons 'exec command opts)))))
+ (match command
+ (() opts)
+ (("--") opts)
+ (("--" command ...) (alist-cons 'exec command opts))))))
(define (assert-container-features)
"Check if containers can be created and exit with an informative error