in reply to How to write a perl script to work on many OS(s)
Use forward slashes (aka virgules). Generally, Perl will treat / as the path delimiter in Windows; see here. Quoting: "Since all DOS and Windows versions since something like MS-DOS 2.0 or so have treated / and \ the same in a path, you might as well use the one that doesn't clash with Perl--or the POSIX shell, ANSI C and C++, awk, Tcl, Java, or Python, just to mention a few. POSIX paths are more portable, too." (perlfaq5)
Note that different shells have different quoting conventions, and different methods of determining when variable substitution should take place.
emc
Any New York City or Connecticut area jobs? I'm currently unemployed.
There are some enterprises in which a careful disorderliness is the true method.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: How to write a perl script to work on many OS(s)
by archfool (Monk) on Jul 06, 2007 at 15:06 UTC | |
by swampyankee (Parson) on Jul 06, 2007 at 19:56 UTC | |
Re^2: How to write a perl script to work on many OS(s)
by GrandFather (Saint) on Jul 06, 2007 at 05:42 UTC | |
by wazoox (Prior) on Jul 06, 2007 at 11:21 UTC |