5HT / fs

📁 FS: Windows, Linux, Mac Driver
https://fs.n2o.dev
Other
234 stars 69 forks source link

Fixing events of unicode filenames #60

Closed dominicletz closed 3 years ago

dominicletz commented 3 years ago

Hi this attached two patches fixes handling of unicode filenames in linux and macos. Both systems use by default utf8 and hence this fix will work for most environments.

Before this patch unicode names would be distorted after the use of the regular pattern match. You can easily try with a filename such as 臺灣.txt Put it into a directory and trigger the change with touch 臺灣.txt

For windows I've no idea how to fetch the current system environment encoding -- or how filenames are being encoded at all -- Have no machine handy atm. So might look into windows later.

5HT commented 3 years ago

Thank you! Published as https://hex.pm/packages/fs/6.9.0