Unix Power ToolsUnix Power ToolsSearch this book

3.5. What Goes in Shell Setup Files?

Setup files for login shells ( Section 3.4) -- such as .login and .profile -- typically do at least the following:

In the C shell, the .cshrc file is used to establish settings that will apply to every instance of the C shell, not just login shells. For example, you typically want aliases (Section 28.2) available in every interactive shell you run -- but these aren't passed through the environment, so a setup file has to do the job. You may wish to put all of your aliases into another file, such as .aliases, or qualify the name with the shell's name, such as .csh.aliases, to allow for different alias formats between shells, and then you can use the source command to read in that file on startup from .cshrc.

Even novices can write simple setup files. The trick is to make these setup scripts really work for you. Here are some of the things you might want to try:

--TOR and SJC



Library Navigation Links

Copyright © 2003 O'Reilly & Associates. All rights reserved.