Shell Support

Denys Duchier


This module attempts to provide a portable interface for invoking the platform's shell


The module exports:

{Shell.executeProgram +L}
{Shell.executeCommand +L}
executes a program (resp. a shell command). L is a list of virtual strings for the program/command and its arguments. They are each appropriately quoted before being handed to the platform's real shell. If execution is not successful, an exception shell(VS) is raised where VS is the virtual string that was actually passed to the shell for execution.
{Shell.toUserVS +L ?VS}
returns a virtual string representation of the program/command invocation L which is only appropriate for displaying to a user because quoting is omitted.