Name:

bashevaluate executes a shell command and returns its output as a string

Library names:

sollya_obj_t sollya_lib_bashevaluate(sollya_obj_t, ...) sollya_obj_t sollya_lib_v_bashevaluate(sollya_obj_t, va_list)

Usage:

bashevaluate(command) : string -> string bashevaluate(command,input) : (string, string) -> string

Parameters:

Description:

Example 1:

   > bashevaluate("LANG=C date");
   Mon Jun 13 18:50:08 CEST 2016

Example 2:

   > [| bashevaluate("echo Hello") |];
   [|"Hello"|]

Example 3:

   > a = bashevaluate("sed -e 's/a/e/g;'", "Hallo");
   > a;
   Hello
See also: bashexecute
Go back to the list of commands