diff options
author | Efraim Flashner <efraim@flashner.co.il> | 2017-11-01 10:29:59 +0200 |
---|---|---|
committer | Efraim Flashner <efraim@flashner.co.il> | 2017-11-01 10:29:59 +0200 |
commit | 19b7bba1b5f115168b1669325cd51bc66b9dc4b4 (patch) | |
tree | 7b4e77080fe6fbc3a54b8612adc3c5c27ab81d05 /guix/scripts.scm | |
parent | f37931d6632627a24e4eccafa1603ffadb649ff6 (diff) | |
parent | 5010d0e36452882eb95666467bb983efa8cca081 (diff) | |
download | guix-patches-19b7bba1b5f115168b1669325cd51bc66b9dc4b4.tar guix-patches-19b7bba1b5f115168b1669325cd51bc66b9dc4b4.tar.gz |
Merge remote-tracking branch 'origin/master' into core-updates
Diffstat (limited to 'guix/scripts.scm')
-rw-r--r-- | guix/scripts.scm | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/guix/scripts.scm b/guix/scripts.scm index 9ff7f25548..4a7ae7baa3 100644 --- a/guix/scripts.scm +++ b/guix/scripts.scm @@ -67,11 +67,13 @@ reporting." (define* (parse-command-line args options seeds #:key + (build-options? #t) (argument-handler %default-argument-handler)) - "Parse the command-line arguments ARGS as well as arguments passed via the -'GUIX_BUILD_OPTIONS' environment variable according to OPTIONS (a list of -SRFI-37 options) and return the result, seeded by SEEDS. -Command-line options take precedence those passed via 'GUIX_BUILD_OPTIONS'. + "Parse the command-line arguments ARGS according to OPTIONS (a list of +SRFI-37 options) and return the result, seeded by SEEDS. When BUILD-OPTIONS? +is true, also pass arguments passed via the 'GUIX_BUILD_OPTIONS' environment +variable. Command-line options take precedence those passed via +'GUIX_BUILD_OPTIONS'. ARGUMENT-HANDLER is called for non-option arguments, like the 'operand-proc' parameter of 'args-fold'." @@ -85,7 +87,9 @@ parameter of 'args-fold'." (call-with-values (lambda () - (parse-options-from (environment-build-options) seeds)) + (if build-options? + (parse-options-from (environment-build-options) seeds) + (apply values seeds))) (lambda seeds ;; ARGS take precedence over what the environment variable specifies. (parse-options-from args seeds)))) |