process-output->string

[procedure] process-output->string cmd&args &keyword error encoding conversion-buffer-size on-abnormal-exit

[procedure] process-output->string-list cmd&args &keyword error encoding conversion-buffer-size on-abnormal-exit

Gauche: Available in gauche.process module. Runs a cmd&args in a separate process (if it is a string, it is passed to shell; if it is a list, it's used as argument array, and the process is directly sys-exec?ed.), and collects its output. process-output->string returns a single string; where all output lines are concatenated by a whitespace (like backtick escape in the shell). process-output->string-list returns a list of strings, each string is a output line, newline removed.

error keyword arg specifies how to handle the error output. on-abmormal-exit keyword arg specifies how to behave if the process exits with non-zero status.

It is built on top of run-process.