A question of aliases...

Dan Ts'o dan at rna.UUCP
Thu Apr 20 13:06:46 AEST 1989


	This has probably been answered a zillion times, but...

	Why doesn't the CSH alias:

	alias foo "echo $1 hello $2"

	give the expected results:

	% foo a b
	a hello b
	%

	Instead it gives:

	% foo a b
	hello a b
	%

	This is the result on 4.3BSD VAX, Ultrix 2.2 and some version of KSH.

	A friend wanted an alias of:

	% alias ff "find $1 -name $2 -print"

	but the best I could come up with was:

	% alias ff "find \!^ -name \!$ -print"

	Even \!1 and \!2 don't work (I guess they grab real events and not
alias args, but then why do \!^ and \!$ work ?).

	Please email responses. Thanks.


				Cheers,
				Dan Ts'o		212-570-7671
				Dept. Neurobiology	dan at rna.rockefeller.edu
				Rockefeller Univ.	...cmcl2!rna!dan
				1230 York Ave.		rna!dan at nyu.edu
				NY, NY 10021		tso at rockefeller.arpa
							tso at rockvax.bitnet



More information about the Comp.unix.wizards mailing list