malxau / yori

Yori is a CMD replacement shell that supports backquotes, job control, and improves tab completion, file matching, aliases, command history, and more.
http://www.malsmith.net/yori/
MIT License
1.23k stars 30 forks source link

yedit support byte order mark #90

Closed tenox7 closed 3 years ago

tenox7 commented 3 years ago

Since Yedit supports UTF encoding it would be nice if it also supported https://en.wikipedia.org/wiki/Byte_order_mark a lot of UTF16 encoded files in Windows start with U+FEFF BOM character.

malxau commented 3 years ago

I added some limited support for this in commit 74ddb11a955e9f0f57db77588e9c530e7d8662f7 . Note that this can only work when a UTF-16 BOM is present; if not, it is interpreted as UTF-8. I really don't want to get into the IsTextUnicode() quagmire of heuristically trying to distinguish text which could be either.

tenox7 commented 3 years ago

Thank you!!!!!!!!!!

malxau commented 3 years ago

This should be fixed in 1.50, released today. Please let me know if there are further related issues.