SUMMARY: Quotes in a shell script

From: McCaffity, Ray <ray.mccaffity_at_wcg.com>
Date: Tue Aug 07 2001 - 13:08:11 EDT
Thanks to everyone who replied.  The two ways everyone mentioned were either
putting the double quotes encapsulated within single quotes.

echo 'BANNER="This is a banner"' > /etc/default/ftpd

or by using C style escape characters.

echo "BANNER=\"This is a banner\"" 

-----Original Message-----
From: McCaffity, Ray [mailto:ray.mccaffity@wcg.com]
Sent: Tuesday, August 07, 2001 11:54 AM
To: 'sunmanagers@sunmanagers.org'
Subject: Quotes in a shell script


What is the best way to echo quotes within a quote inside a shell script?

echo "BANNER="This is a banner"" > /etc/default/ftpd
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
Received on Tue Aug 7 18:08:11 2001

This archive was generated by hypermail 2.1.8 : Wed Mar 23 2016 - 16:25:01 EDT