Next Prev Up Top Contents Index

call-system

Function
Package

system

Syntax

call-system comand &optional shell-type => status

Arguments

command

A string or a list of strings.

shell-type

A string.

Values

status

The exit status of the invoked shell.

Description

call-system allows executables and Unix shell commands to be called from Lisp code. The output goes to standard output, as the operating system sees it. (This normally means *terminal-io* in LispWorks.)

If command is a string it is the command to execute. If it is a list, the first element of the list is the command and the remaining elements of the list are the command line arguments.

shell-type gives the type of shell required. The default is the Bourne shell, /bin/sh . The C shell may be obtained by specifying "/bin/csh" .

call-system returns the exit status of the shell invoked to execute the command.

Example
(call-system (format nil "adb ~a < ~a > ~a"
                (namestring   a)
                (namestring   b)
                (namestring   c)))
See Also

open-pipe
call-system-showing-output


LispWorks Reference Manual - 14 Dec 2001

Next Prev Up Top Contents Index