Though Path::Class seems to be really good (and maybe I should have used it in place of File::Spec from the beginning), I don't see how it can handle my case, as it seems to require the *caller* to already know which style the pathes are.
For example, when running the following piece of code:
I would have wished that this would outputuse Path::Class; foreach $s ('x/y','x\y') { $dir=Path::Class:Dir->new($s)->as_foreign('Unix'); print "$dir\n"; }
no matter whether the application is running on Unix or on Windows. But on Unix (for example), I getx/y x/y
I understand the behaviour of Path::Class: It is not designed to look into a path string and guess from there what OS type it is supposed to be - but this is the very thing I'm looking for.x/y x\y
In reply to Re^2: CPAN Module for mixing Unix/Windows path
by rovf
in thread CPAN Module for mixing Unix/Windows path
by rovf
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |