common-lisp/ambrevar: Auto-flatten arg list.

master
Pierre Neidhardt 2020-11-07 18:27:35 +01:00
parent d1a5c95939
commit 7b579ff7cd
1 changed files with 3 additions and 2 deletions

View File

@ -86,7 +86,7 @@ Without PREDICATES, list all files."
(push process-info *process-list*)
(uiop:wait-process process-info)))
(setf command (if (listp command)
(mapcar #'princ-to-string command)
(mapcar #'princ-to-string (alex:flatten command))
command))
;; TODO: Use :stream directly in launch-program and get stream from
;; process-info to avoid repeating the launch-program call.
@ -115,7 +115,8 @@ Without PREDICATES, list all files."
If on interrupt process gets forked to the background, call
`terminate-dangling-processes'.
Output is sent to `*standard-output*'.
Arguments are automatically converted to strings with `format'."
Arguments are automatically converted to strings with `format'.
Lists are automatically flattened."
(%run (cons command args) :output t))
(export-always 'run*)