Re: alias in tcsh

From: Bill Marcum (bmarcum_at_iglou.com.urgent)
Date: 12/03/03


Date: Tue, 2 Dec 2003 22:20:08 -0500

On 1 Dec 2003 19:01:56 -0800, M
  <greenandkind@yahoo.com> wrote:
> Hello all,
>
> I am trying to set a simple alias in my .profile
> The deafault shell we're working in is ksh. In .profile, I set it to
> tcsh that I am so used to and dearly love, and in the next line try to
> set simple alias, say: alias ls 'ls -l -a'. This, I understand should
> be the correct syntax for tcsh, but it seems that somehow, while
> executing tcsh from .profile, it is still doesn't recognize it at the
> point of execution of the next line. So it rejects the alias syntax.
> If I use ksh syntax for alias, it still doesn't work, because after
> execution of .profile, I'm already in tcsh.
> Could someone point me to a solution of this little nuisance?
>
If you wrote it like this:

tcsh
alias ls 'ls -l -a'

it won't work, because the alias command isn't seen until tcsh exits.
The proper way is (a) change your shell with "chsh", or (b) end your
.profile with "exec tcsh", and put the alias in .cshrc.

-- 
Thanks to Nigeria, any email with the word "urgent" in the subject 
or address will be deleted.


Relevant Pages

  • alias in tcsh
    ... I am trying to set a simple alias in my .profile ... The deafault shell we're working in is ksh. ... tcsh that I am so used to and dearly love, and in the next line try to ...
    (comp.unix.shell)
  • Re: Hey it worked!! autocomplete: account passwords not saved
    ... The old registry key isn't doing any harm, but I suppose you can delete it ... Please do not send email directly to this alias. ... > to new profile is ... >>> AutoComplete Does Not Save Username and Password ...
    (microsoft.public.windowsxp.security_admin)
  • Hey it worked!! autocomplete: account passwords not saved
    ... to new profile is ... you should see an entry ... >Please do not send email directly to this alias. ... >> AutoComplete Does Not Save Username and Password ...
    (microsoft.public.windowsxp.security_admin)
  • Re: Exchange 2003 and Pop3 passwords not being accepted.
    ... It appears that the alias helps and resolves. ... The only differances between the accounts that I found is that the smtp ... the user profile user name. ... local.domain entry maching the email address entries. ...
    (microsoft.public.exchange.admin)
  • Re: autocomplete: account passwords not saved
    ... copying your stuff over the to new profile is ... way to recover from this except be creating a new database. ... Please do not send email directly to this alias. ... >>> As Administrator and with autocomplete on no passwords ...
    (microsoft.public.windowsxp.security_admin)