in reply to Re: Removing glob
in thread Removing glob

Simply using real slashes, ie glob "$dir/files/*.txt" tends to work regardless of spaces

Replies are listed 'Best First'.
Re^3: Removing glob
by Corion (Patriarch) on Feb 19, 2011 at 08:25 UTC

    No:

    c:\windows\system32>perl -wle "print for glob shift" "C:/Program Files +/*" C:/Program

    Using File::Glob::bsd_glob works as it should:

    c:\windows\system32>perl -MFile::Glob=bsd_glob -wle "print for bsd_glo +b shift" "C:/Program Files/*" C:/Program Files/HP

    ... but the direction of slashes does not matter:

    c:\windows\system32>perl -MFile::Glob=bsd_glob -wle "print for bsd_glo +b shift" "C:\Program Files\*" C:\Program Files\HP