Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 06-02-2008, 08:16 AM   #1
Registered: Aug 2007
Posts: 134

Rep: Reputation: 15
Unhappy what is .cshrc

Good Morning

Can any one please explain me what is .cshrc file ?
why is it used?

Waiting for your reply.

Thanks and Regards
Old 06-02-2008, 08:23 AM   #2
LQ Newbie
Registered: May 2008
Posts: 1

Rep: Reputation: 0
It's used to set environment variables, aliases, etc.

When you launch a new terminal ( or new shell ) then this file is read in ( assuming using the c shell ... you can have different shells like bash,zsh, sh etc which read in their own versions)

Anyway, each time you get a new C shell the environment set up in the .chsrc will be setup
Old 06-02-2008, 08:23 AM   #3
Senior Member
Registered: May 2008
Location: planet earth
Distribution: Debian
Posts: 1,732

Rep: Reputation: 50
If you have 'csh' installed (or at least its documentation):

man csh

Then look through for the discussion on .cshrc

If you don't have the csh docs, try the bash docs and look for .bashrc:

man bash
Old 06-04-2008, 08:38 AM   #4
Registered: Feb 2008
Location: Uns Cigano from Vigol
Distribution: FreeBSD 8.0
Posts: 59

Rep: Reputation: 19

Some tips on .cshrc / csh.cshrc / csh
1. The csh is usually installed as /bin/csh
1.1. But in the most cases, especially in linux distros, it's a symbolic link to /bin/tcsh
1.2. csh (C Shell) is developed for BSD systems; I think, by Bill Joe, in the Berkley.
1.3. tcsh (TENEX/TOPS C shell) is a new version of C Shell that have some new features like
1.3.1. Command history scrolling
1.3.2. Command editing with R/L Arrow keys
1.3.3 Formatting the prompts
1.3.4. A spelling correction facility
1.3.5. Advances word completion
1.4. For more infos refer to :
1.4.1. I supposed that above link still in live.
2. Result :
2.2. Almost in many situations, the TCSH will trace your .cshrc .
2.1. And commadns like info/man csh will direct you to the info/man tcsh pages.
3. When you log int ot the sys with csh/tcsh, these proccesses'll ocur, in order:
3.1. csh/tcsh execute commands from csh.cshrc and csh.login
3.1.1. Both of them reside on /etc
3.2. csh/tcsh execute commands from .tcshrc |or| .cshrc.
3.2.1. It's first read .tcshrc, if that not exist : It'll read .cshrc .
3.2.2. Both of them reside on /home/USER...
3.3. fetch others command from another files : .history, .login, .cshdirs ...(Maybe in order or ?!).

mehrshad moslehi


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Where is .cshrc? johnpaulodonnell Linux - Newbie 4 05-30-2008 07:59 PM
problem with source .cshrc xrin Linux - Distributions 1 02-13-2007 06:25 AM
Suse 10.0 .cshrc setup munichtexan SUSE / openSUSE 1 01-19-2006 01:11 PM
.login, .bashrc or .cshrc ??? tuananhbirm Linux - General 1 01-20-2005 10:44 AM
cannot find .cshrc , please help slice4e Linux - General 4 05-12-2003 02:38 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:23 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration