ambrevar/shell: Add tee.
parent
40838e883c
commit
f0cad5decb
|
@ -260,6 +260,15 @@ to get the final output as a string."
|
|||
(values (uiop:process-info-output handler)
|
||||
handler)))
|
||||
|
||||
(export-always 'tee)
|
||||
(defun tee (input-stream)
|
||||
"Return the INPUT-STREAM and its string representation as a second value."
|
||||
(let ((result
|
||||
(uiop:slurp-stream-string input-stream :stripped t)))
|
||||
(values
|
||||
(make-string-input-stream result)
|
||||
result)))
|
||||
|
||||
(export-always 'disk-usage)
|
||||
(defun disk-usage (files)
|
||||
"Return disk usage of FILES in octets.
|
||||
|
|
Loading…
Reference in New Issue