in reply to Windows quoting

If the argument starts with \", we are out of luck (at least I have not found yet a way how to encode the string '\\"foo' properly for my batchfile

Using the following cmd file as the mechanism of demonstration (called echoem.cmd):

@echo off perl -wle"print qq['$_'] for @ARGV" %*

Does this achieve what you are after?

C:\test>echoem "\"foo" "bar \"qux" \\\"foo '"foo' ### $1 'bar "qux' ### $2 '\"foo' ### $3

Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."

Replies are listed 'Best First'.
Re^2: Windows quoting
by rovf (Priest) on Jul 22, 2008 at 08:31 UTC
    \\\"foo

    Indeed it does! Thanks a lot!

    -- 
    Ronald Fischer <ynnor@mm.st>