A question of aliases...

kai at uicsrd.csrd.uiuc.edu kai at uicsrd.csrd.uiuc.edu
Fri Apr 21 22:41:00 AEST 1989


>/* Written 10:06 pm  Apr 19, 1989 by dan at rna.UUCP in uicsrd.csrd.uiuc.edu:comp.bugs.4bsd */
> Why doesn't the CSH alias:
>	alias foo "echo $1 hello $2"
> give the expected results:
>	% foo a b
>	a hello b
>				Dan Ts'o		212-570-7671
>				Dept. Neurobiology	dan at rna.rockefeller.edu
>				Rockefeller Univ.	...cmcl2!rna!dan

Try something like:
	alias foo 'set argv = ( \!* ); echo $1 hello $2'
This does what you want (on 4.3 BSD).


Patrick Wolfe  (pat at kai.com,  kailand!pat)
System Manager, Kuck & Associates, Inc.



More information about the Comp.unix.wizards mailing list