On Windows you could try to query the current codepage somehow, and hope that the filename is in that codepage (I don't think it's guaranteed though), on Unix systems you could try the current locale - but then again you can't blindly assume that it reflects the encoding of the file name.
If you have a narrow selection of possible encodings, you can use Encode::Guess to determine which one is most likely correct, but it's only a heuristic, and usually doesn't work well on such short strings as file names.
In reply to Re: find scalar encoding
by moritz
in thread find scalar encoding
by rastakouair
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |