Search the FAQ Archives

3 - A - B - C - D - E - F - G - H - I - J - K - L - M
N - O - P - Q - R - S - T - U - V - W - X - Y - Z
faqs.org - Internet FAQ Archives

Unix - Frequently Asked Questions (5/7) [Frequent posting]
Section - What "dot" files do the various shells use?

( Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Single Page )
[ Usenet FAQs | Web FAQs | Documents | RFC Index | Business Photos and Profiles ]


Top Document: Unix - Frequently Asked Questions (5/7) [Frequent posting]
Previous Document: How can I tell if I am running an interactive shell?
Next Document: I would like to know more about the differences ... ?
See reader questions & answers on this topic! - Help others by sharing your knowledge
>From: tmb@idiap.ch (Thomas M. Breuel)
Date: Wed, 28 Oct 92 03:30:36 +0100

5.6)  What "dot" files do the various shells use?

      Although this may not be a complete listing, this provides the
      majority of information.

      csh
          Some versions have system-wide .cshrc and .login files.  Every
          version puts them in different places.

          Start-up (in this order):
              .cshrc   - always; unless the -f option is used.
              .login   - login shells.

          Upon termination:
              .logout  - login shells.

          Others:
              .history - saves the history (based on $savehist).

      tcsh
          Start-up (in this order):
              /etc/csh.cshrc - always.
              /etc/csh.login - login shells.
              .tcshrc        - always.
              .cshrc         - if no .tcshrc was present.
              .login         - login shells

          Upon termination:
              .logout        - login shells.

          Others:
              .history       - saves the history (based on $savehist).
              .cshdirs       - saves the directory stack.

      sh
          Start-up (in this order):
              /etc/profile - login shells.
              .profile     - login shells.

          Upon termination:
              any command (or script) specified using the command:
                 trap "command" 0

      ksh
          Start-up (in this order):
              /etc/profile - login shells.
              .profile     - login shells; unless the -p option is used.
              $ENV         - always, if it is set; unless the -p option is used.
			  /etc/suid_profile - when the -p option is used.

          Upon termination:
              any command (or script) specified using the command:
                 trap "command" 0

      bash
          Start-up (in this order):
              /etc/profile  - login shells.
              .bash_profile - login shells.
              .profile      - login if no .bash_profile is present.
              .bashrc       - interactive non-login shells.
              $ENV          - always, if it is set.

          Upon termination:
              .bash_logout  - login shells.

          Others:
              .inputrc      - Readline initialization.

      zsh
          Start-up (in this order):
              .zshenv   - always, unless -f is specified.
              .zprofile - login shells.
              .zshrc    - interactive shells, unless -f is specified.
              .zlogin   - login shells.

          Upon termination:
              .zlogout  - login shells.

      rc
          Start-up:
              .rcrc - login shells

User Contributions:

Comment about this article, ask questions, or add new information about this topic:

CAPTCHA




Top Document: Unix - Frequently Asked Questions (5/7) [Frequent posting]
Previous Document: How can I tell if I am running an interactive shell?
Next Document: I would like to know more about the differences ... ?

Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Single Page

[ Usenet FAQs | Web FAQs | Documents | RFC Index ]

Send corrections/additions to the FAQ Maintainer:
tmatimar@isgtec.com (Ted Timar)





Last Update March 27 2014 @ 02:12 PM