[net.unix-wizards] Unmatched ". bug in csh

lab@qubix.UUCP (07/06/83)

When trying to set up some vi abbreviations in my .login file,
I was constantly stymied by an annoying error message:
	Unmatched ".

which came from the following lines of my .login file:
	setenv EXINIT 'set ai redraw sm wm=14\
		ab qad Larry Bickford, decvax\!decwrl\!qubix\!lab'

If you see a " anywhere on those lines, I would be happy to know.
This is doubly infuriating since later in .login I have a WORKING syntax:

	setenv EXINIT "$EXINIT"'\
		<more exinit initializers>\
		<last initializer>'

I have tried rearranging the first group in a ton of ways over the
two lines (including the second form), but get the same idiotic
error. If I move the abbreviation to the second setenv, or split
the first into two setenv's (each on its own line), it works.
WHAT IS GOING ON HERE???

Larry Bickford, {ucbvax,decvax}!decwrl!qubix!lab

SJOBRG.ANDY%MIT-OZ%mit-mc@sri-unix.UUCP (07/09/83)

The problem is the \n in the first setenv. It goes into the variable just
fine, but when EXINIT is expanded in the second setenv, the newline gets
expanded in with it...and csh is stupid about things like newlines without
'\'s before them. Even if you place extra '\' within the first setenv,
it STILL won't work. Csh loses over sh on things like this. Sigh.

	-andy