Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

< Previous PageNext Page > Hide TOC

General Tools

The tools in this section are general tools that don’t fit into any broad categories.

Table A-1  Commonly-used general scripting tools

Tool

Description

bc

Short for “basic calculator”, performs floating point math and various other useful calculations that are not practical with basic shell math support.

expect

Used to work with hard-to-handle command-line tools that require more complex interaction than is possible with a single pipe. For example, you could use an expect script to interact with getty over a tty or other bidirectional connection to log into a remote computer. In general, scripting that requires two-way interaction between the script and a program is most easily done with an expect script.

expr

Evaluates a numerical expression. This command supports basic integer math, and is frequently used for incrementing a loop iterator.

false

Returns a failure exit status (nonzero).

sleep

Pauses execution for a period of time (measured in seconds).

true

Returns a successful exit status (0).



< Previous PageNext Page > Hide TOC


Last updated: 2008-04-08




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Get information on Apple products.
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Copyright © 2007 Apple Inc.
All rights reserved. | Terms of use | Privacy Notice