Tools: MPW
Advanced Search
Apple Developer Connection
Member Login Log In | Not a Member? Support

MPW Command Reference


Shutdown

Built-in

SYNTAX

Shutdown [-c | -n | -y] [-r]

DESCRIPTION

The Shutdown command quits MPW and all other open applications and then either shuts down (the default) or reboots the Macintosh (-r). If you have modified any files, a confirmation dialog box appears asking whether you want to save the changes. You can use the -c, -n, or -y options in scripts to handle this question noninteractively.

INPUT

None

OUTPUT

None

STATUS

Shutdown can return the following status codes:

1

syntax error

2

command aborted

Note
Shutdown cannot return a status of 0. If there are no errors, it is impossible to return a status code because the MPW Shell has already quit. •

PARAMETERS

None

OPTIONS

-c

Prevents the display of any confirmation dialog boxes by automatically responding Cancel. This causes the command to abort if any windows need to be saved.

-n

Prevents the display of any confirmation dialog boxes by automatically responding No. This causes all modified windows to be closed without saving any changes.

-r

Reboots the Macintosh.

-y

Prevents the display of any confirmation dialog boxes by automatically responding Yes. This causes all modified windows to be saved before closing.

EXAMPLES

The following command line shuts down the Macintosh, automatically saving all modified windows.

Shutdown -y

SEE ALSO

Quit

 
 


Last Updated July 2000