X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=blobdiff_plain;f=guestfs-actions.pod;h=93a9fbb7843d8128b4520f34a6700f17caa3691a;hp=f37ec50bd39eb69a6596ebfc2d65969bab9f52b3;hb=4211c7a258debd236017a19c70965bc1b3658edb;hpb=57d2dfab18ad3d987d9273bb7c1f42e73e0bbcb2 diff --git a/guestfs-actions.pod b/guestfs-actions.pod index f37ec50..93a9fbb 100644 --- a/guestfs-actions.pod +++ b/guestfs-actions.pod @@ -511,7 +511,9 @@ or compatible processor architecture). The single parameter is an argv-style list of arguments. The first element is the name of the program to run. Subsequent elements are parameters. The list must be -non-empty (ie. must contain a program name). +non-empty (ie. must contain a program name). Note that +the command runs directly, and is I invoked via +the shell (see C). The return value is anything printed to I by the command. @@ -546,6 +548,8 @@ FTP. This is the same as C, but splits the result into a list of lines. +See also: C + This function returns a NULL-terminated array of strings (like L), or NULL if there was an error. I. @@ -1649,6 +1653,41 @@ not intended to be parsed. This function returns a string, or NULL on error. I. +=head2 guestfs_sh + + char *guestfs_sh (guestfs_h *handle, + const char *command); + +This call runs a command from the guest filesystem via the +guest's C. + +This is like C, but passes the command to: + + /bin/sh -c "command" + +Depending on the guest's shell, this usually results in +wildcards being expanded, shell expressions being interpolated +and so on. + +All the provisos about C apply to this call. + +This function returns a string, or NULL on error. +I. + +=head2 guestfs_sh_lines + + char **guestfs_sh_lines (guestfs_h *handle, + const char *command); + +This is the same as C, but splits the result +into a list of lines. + +See also: C + +This function returns a NULL-terminated array of strings +(like L), or NULL if there was an error. +I. + =head2 guestfs_sleep int guestfs_sleep (guestfs_h *handle,