Can sh or csh do this VMS DCL trick??

Chris Torek torek at elf.ee.lbl.gov
Mon Apr 29 01:29:05 AEST 1991


In article <1991Apr28.003414.26784 at convex.com> tchrist at convex.COM
(Tom Christiansen) describes `here-documents', and concludes with
>In Bourne-compatible shells (and perl) you can control whether variables
>get interpolated in the intervening text: just quote the token (in this
>case EOD), and you quote the text.  The csh, to no one's great surprise,
>has no such ability.

Actually, it does.  It is merely somewhat annoying about it.  In sh,

	cat << \end
	foo
	end

and

	cat << 'end'
	foo
	end

do the same thing.  In the C shell these must be spelled as

	cat << \end
	foo
	\end

and

	cat << 'end'
	foo
	'end'

respectively.
-- 
In-Real-Life: Chris Torek, Lawrence Berkeley Lab CSE/EE (+1 415 486 5427)
Berkeley, CA		Domain:	torek at ee.lbl.gov



More information about the Comp.unix.questions mailing list