A Shell Question
Tom Callahan
callahant at tessco.com
Mon Jan 9 14:53:48 UTC 2006
you have the right idea. As far as getting your profile to load
correctly after executing tcsh...either run "source /etc/profile" or ".
/homedir/.tcshprofile" note the space after the period.
I am unaware of a different way to do this, besides defining it in
usermod. I guess you could create a wrapper of sorts to act as your
shell, and depening on the returned $HOSTNAME variable launch the
appropriate shell....not sure if this would work though. IE: write a
shell script that checks the variable, and then launches the appropriate
shell, name this script /bin/customlogin. Using usermod, set your
default shell to /bin/customlogin.
Again, I'm not sure if this would work, but it seems relatively valid...
Thanks,
Tom Callahan
TESSCO Technologies
(443)-506-6216
callahant at tessco.com
A real engineer only resorts to documentation when the keyboard dents on the forehead get too noticeable.
Padiyath Sreekumaran wrote:
> Hello,
> I have the following question. Iam having my HOME directory
> on AFS and the default shell is bash. But when Iam logging
> on a desktop linux machine(pc1234) (afs SW is installed on this
>machine)
> I would like to have tc-shell. So I did the following changes
> in my .bashrc file for that:
>
> if [ $HOSTNAME == "pc1234" ]
>then
> cd /home/username
> /bin/tcsh
>fi
>
> With this I can have tcshell. But the file .cshrc with number of
> local definitions(alias, senenv) are not executed and I have to
> write twice exit to logout from my session(first from tcshell
>session
> and then from bash). I donot want to change the shell permanently
> with chsh command. I would like to have tcshell only when Iam on
>pc1234
> and like to have .cshrc executed.
>
> Thanks in advance.
> Regards,
> Kumar
>
>------------------------------------------------------------------
>Padiyath Sreekumar | Tel: +41.56.310.3643
>Paul Scherrer Institut | email: kumar.padiyath at psi.ch
>AIT | Office: WHGA/U132
>WHGA/U132 | Fax: +41.56.310.3649
>CH-5232 Villigen PSI |
>Switzerland |
>-----------------------------------------------------------------
>
>
>
More information about the redhat-list
mailing list