Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: windows path problem

by ikegami (Patriarch)
on Aug 19, 2010 at 15:34 UTC ( #856066=note: print w/replies, xml ) Need Help??


in reply to windows path problem

I'm not sure why you'd need to do that. Normally, you need to double the slashes in a string literal so it produces a string with single backslashes.

>perl -le"print qq{c:\\abc\\xyz};" c:\abc\xyz

You do not want to pass doubled slashes to open.

Replies are listed 'Best First'.
Re^2: windows path problem
by TomDLux (Vicar) on Aug 19, 2010 at 19:44 UTC
    But you might want double quotes if you're going to be using the shell, as in
    system( "dir $path" );
    rather than bypassing the shell
    system( 'dir', $path )';
    Disclaimer: I'm a Unix guy. This would be true on Unix; does "MS-DOS 2010" still have a shell?

    --
    TTTATCGGTCGTTATATAGATGTTTGCA

      No, you wouldn't. "\" is not special to the cmd shell, and it doesn't use "\" for escaping.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://856066]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2022-01-22 23:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:












    Results (63 votes). Check out past polls.

    Notices?