The only previous mention I could find of this was over a decade ago and
I hope ancient history. Running 5.32 on win10 and I have the unfortunate situation of having a bunch of files with Unicode in the file names. This, apparently, doesn't bother win10 but I'd like to get rid of the garbage and Perl can't seem to access them, quite. I do an opendir/readdir to get the file name. When I look at the file with windows I see things like
___________________________ ✈️ ✈️ ✈
+5039;
but when I look at the file name in Perl I see
___________________________ ?? ?? ??
and if i try to access the file from Perl I get an "can't find the file" and i even tried doing it via windows with
system "ren \'$UNIFILE\' $reasonablename"
and windows can't see the file {and of course trying "-f $UNIFILE" in perl tells me that it isn't there}.
I've always been hopelessly confused in dealing with Unicode in perl but from what I have read, it seems that it is all supposed to "just work"... but apparently not for file names and accessing the file system.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.