* confusion over the proper way to make an alias
@ 1997-11-07 14:54 Timothy J Luoma
1997-11-07 15:33 ` Peter Stephenson
0 siblings, 1 reply; 3+ messages in thread
From: Timothy J Luoma @ 1997-11-07 14:54 UTC (permalink / raw)
To: zsh-users
I have been setting up a new zsh account on a LINUX machine running ZSH
3.0.3 and found that I could not use:
alias ls="ls $LS_OPTIONS"
I had to use
alias ls="command ls $LS_OPTIONS"
or else I got the 'job table full' message mentioned in the FAQ.
I went to my NeXT machine running 3.0.5 and found that if I used:
alias ls="command ls $LS_OPTIONS"
I got:
/usr/local/gnu/bin/ls: ls: No such file or directory
but if I used
alias ls="ls $LS_OPTIONS"
then it worked OK.
Can someone explain what is going on and what the proper way to set the alias is?
Thanks
TjL
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: confusion over the proper way to make an alias
1997-11-07 14:54 confusion over the proper way to make an alias Timothy J Luoma
@ 1997-11-07 15:33 ` Peter Stephenson
1997-11-07 15:35 ` Timothy J Luoma
0 siblings, 1 reply; 3+ messages in thread
From: Peter Stephenson @ 1997-11-07 15:33 UTC (permalink / raw)
To: Timothy J Luoma, Zsh users list
Timothy J Luoma wrote:
>
> I have been setting up a new zsh account on a LINUX machine running ZSH
> 3.0.3 and found that I could not use:
>
> alias ls="ls $LS_OPTIONS"
>
> I had to use
>
> alias ls="command ls $LS_OPTIONS"
>
> or else I got the 'job table full' message mentioned in the FAQ.
That means you have function, as well as an alias, defined to ls(). It's
possible to have both, but only the function can fill your job table and
needs the `command ls' inside it. (Also, remember the catch: if you define
an alias for ls, and the function next with 'ls() {...}', the alias
gets expanded in the definition, causing havoc.)
> I went to my NeXT machine running 3.0.5 and found that if I used:
>
> alias ls="command ls $LS_OPTIONS"
>
> I got:
> /usr/local/gnu/bin/ls: ls: No such file or directory
This should certainly work. I can only think of checking paths, value
of $LS_OPTIONS, symbolic links, everything you've probably thought of.
--
Peter Stephenson <pws@ifh.de> Tel: +49 33762 77366
WWW: http://www.ifh.de/~pws/ Fax: +49 33762 77413
Deutsches Elektronen-Synchrotron --- Institut fuer Hochenergiephysik Zeuthen
DESY-IfH, Platanenallee 6, 15738 Zeuthen, Germany.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: confusion over the proper way to make an alias
1997-11-07 15:33 ` Peter Stephenson
@ 1997-11-07 15:35 ` Timothy J Luoma
0 siblings, 0 replies; 3+ messages in thread
From: Timothy J Luoma @ 1997-11-07 15:35 UTC (permalink / raw)
To: Peter Stephenson; +Cc: Zsh users list
Author: Peter Stephenson <pws@ifh.de>
Original-Date: Fri, 07 Nov 1997 16:33:34 +0100
Message-ID: <199711071533.QAA05401@hydra.ifh.de>
> That means you have function, as well as an alias, defined to ls(). It's
> possible to have both, but only the function can fill your job table and
> needs the `command ls' inside it. (Also, remember the catch: if you define
> an alias for ls, and the function next with 'ls() {...}', the alias
> gets expanded in the definition, causing havoc.)
Nailed it.
Thanks Peter.
TjL, insanely stupid today
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1997-11-07 15:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-11-07 14:54 confusion over the proper way to make an alias Timothy J Luoma
1997-11-07 15:33 ` Peter Stephenson
1997-11-07 15:35 ` Timothy J Luoma
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).