<<< Date Index >>>     <<< Thread Index >>>

Re: quoting in my_hdr (was X-Face errors)



On 2004-01-16, Nick Urbanik <nicku@xxxxxxxxxx> wrote:
> On Tue, Jan 13, 2004 at 07:42:48PM -0500, David Yitzchak Cohen wrote:
> > On Sat, Jan 10, 2004 at 08:29:35PM +0800, Nick Urbanik wrote:
> > 
> > > I quoted all the ' inside the ''s with a backslash, but still same
> > > results.
> > 
> > Have you tried quoting all the semicolons in your statement, as well?
> 
> Yes, I progressively quoted more and more within the single quotes,
> including the hashes, with progressively more bizarre permutations,
> until I came to the conclusion that this statement from the manual:
> 
>   The difference between the two types of quotes is similar to
>   that of many popular shell programs, namely that a single quote
>   is used to specify a literal string (one that is not
>   interpreted for shell variables or quoting with a backslash
>   [see next paragraph]), while double quotes indicate a string
>   for which should be evaluated.
> 
> is not totally accurate; at least, it does not quite match the
> way my shells handle quoting.  Does anyone know how to quote
> stuff so that my_hdr really gets what is required?

To put a ' within '', use in place of each ' the following:

    '\''

I believe the first ' closes the quote, then the \' inserts a ',
then the last ' opens a new quote.

HTH,
Gary

-- 
Gary Johnson                               | Agilent Technologies
garyjohn@xxxxxxxxxxxxxxx                   | Wireless Division
http://www.spocom.com/users/gjohnson/mutt/ | Spokane, Washington, USA