O'Reilly logo

Learning Unix for Mac OS X Tiger by Dave Taylor

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Customizing your Unix Experience

One of the great values of Unix is that it's flexible, and what's the point of all this flexibility if you can't bend it to meet your own needs? Let's finish up this book with a brief tour of the different ways you can reshape your Mac OS X Unix world.

Shell Aliases and Functions

If you type command names that are hard for you to remember, or command lines that seem too long, you'll want to learn about shell aliases and shell functions. These shell features let you abbreviate commands, command lines, and long series of commands. In most cases, you can replace them with a single word or a word and a few arguments. For example, one of the long pipelines (see Chapter 6) could be replaced by an alias or function (for instance, aug). When you type aug at a shell prompt, the shell would list files modified in August, sorted by size. This might look like:

alias aug="ls -l | grep Aug"

Making an alias or function is almost as simple as typing in the command line or lines that you want to run. References earlier in this chapter have more information. Shell aliases and functions are actually a simple case of shell programming . For more information on aliases, see Chapter 2.

Programming

There are a number of different ways that you can delve into the world of programming, ranging from the lightweight interpreted shell script to full C++ or Java development. They're all supported within the Mac OS X environment.

Shell scripts

I mention earlier that the shell is the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required