[comp.unix.shell] more ' fun!!!

nichols@en.ecn.purdue.edu (Scott P Nichols) (03/14/91)

OK, in csh, I want to have this string echo'd...     ^[=@'^[H8
Problem being, I can't get the ' to be echo'd.
(I am putting this command into a shell script.)
If I use the command...

echo '=@'H8'

...it thinks the string to be echo'd ends at the second '
If I use the command...

echo '=@\'H8'

...it sees the \ as a character, thus moving the the wrong
cursor position (this is a terminal plotting command).

Any ideas?

SN
-- 
O-        /\
|\     /\/vv\
      /vv\   \        	      __Insight from Oregon...Scott P. Nichols
_____/    \   ~~~~~~~~~~~~~~~~                      (nichols@en.ecn.purdue.edu)

luj@gus16.ecn.purdue.edu (Jun Lu) (03/14/91)

In article <1991Mar13.211216.8061@en.ecn.purdue.edu> nichols@en.ecn.purdue.edu (Scott P Nichols) writes:
>OK, in csh, I want to have this string echo'd...     ^[=@'^[H8
>Problem being, I can't get the ' to be echo'd.
>(I am putting this command into a shell script.)
>If I use the command...
>
>echo '=@'H8'
>
>...it thinks the string to be echo'd ends at the second '
>If I use the command...
>
>echo '=@\'H8'
>
>...it sees the \ as a character, thus moving the the wrong
>cursor position (this is a terminal plotting command).
>
>Any ideas?
>
Try

	echo "^[=@'^[H8"
--
-- Jun Lu                          Internet:luj@ecn.purdue.edu          --
-- Aeronautics & Astronautics      Bitnet:  luj%ecn.purdue.edu@purccvm  --
-- Purdue University               UUCP:    pur-ee!luj                  -- 
-- W. Lafayette, IN 47907          Phone:317-494-9410  Fax:317-494-0307 --