Apple Shake 4 User Manual

Page 394

Advertising
background image

394

Chapter 14

Customizing Shake

Environment variables are strings of information, such as a specific hard drive, file
name, or file path, set through a shell (for example, in Terminal on a Mac OS X system)
that is associated with a symbolic name (that you determine). This information is stored
in a hidden file. Each time you launch Shake, the operating system and the Shake
application look at the hidden file to set the environment variables. In other words,
defining environment variables is the equivalent of setting user-defined system
preferences.

As a simple example, you can set an environment variable that specifies a folder that
Shake scans (on launch) for additional fonts used by the Text or AddText node.

To set environment variables on a Mac OS X system, create and edit a “.plist,” or
property list, file. Using the .plist sets variables for Shake whether it is launched from
the Terminal or from the Shake icon.

Using the above example of a font folder, to instruct Shake to read the /System/Library/
Fonts
folder, set the following environment variable in your .plist file:

<key>NR_FONT_PATH</key>

<string>/System/

Library/Fonts

</string>

Another way to define environment variables is to use the setenv command in a .tcshrc
(enhanced C shell resource) file. Each time the Terminal is launched, the .tcshrc file is
read. The environment variables defined by the .tcshrc file are only read by Shake when
launched from the Terminal.

Using the above example of a font folder, to instruct Shake to read the /System/Library/
Fonts
folder, set the following environment variable in your .tcshrc file:

setenv NR_FONT_PATH /System/Library/Fonts

Note: The .tcshrc file can be used on all Shake platforms (Mac OS X and Linux).

A common use for a user’s personal .plist or .tcshrc file is to define commonly used
aliases for commands. As a simple example, you can set an environment variable to
launch Shake from the Terminal.

An alias in the command line is not the same as an alias on the Macintosh operating
system. In the OS, an alias merely points to another file. In the command line, you
create an alias to assign your own name to a command.

Note: If you do not have environment variables set on your Mac OS X system, you can
still launch Shake from the Terminal by typing the complete path to Shake:

/Applications/Shake4/shake.app/Contents/MacOS/shake

Advertising