in reply to Cross platform compatability Part 1: Shells and Files

I've been under the impression that any decent port of Perl worked with / as a directory delimiter, no matter what the OS considered it to be.

If you want to be hardcore, you could store all pathnames using File::Basename and extract a filesystem specific string for FS calls.

  • Comment on Re: Cross platform compatability Part 1: Shells and Files

Replies are listed 'Best First'.
Re: Re: Cross platform compatability Part 1: Shells and Files
by jepri (Parson) on Jan 21, 2001 at 20:34 UTC
    Yes, you are quite correct. However my point wasn't to start up a new module war, just to point out how with a few smallish changes that are pretty much good programming practise anyway, that code can made cross-platform. I felt that saying someone should go and learn Yet Another Module would be a bit too much (does anyone else dread the task of reading through the docs for all modules related to a task, then trialling them all to see which ones work well?)

    Update: chipmunk pointed out that '/' is not a directory separator for every good port - the Mac does things differently.

    ____________________
    Jeremy
    I didn't believe in evil until I dated it.