Hi Hans, Pablo,
But I do agree that the line ending handling seems a little odd. I find it surprising that the buffers internally use CR line endings since no systems in the past 20 years use that.
how about tex ...
\number\endlinechar \number\numexpr`M-`A+1\relax % plain sets up `^^M
Argh, how could I have forgotten about that. Yes, that makes complete sense.
First, run "chcp 65001" before running "context" and record the size of the file written. Then, run "chcp 1251" and run "context" again. Hopefully the file size doesn't change; but if it does, then that means that the binary content of any file written will depend on the system's default code page, which would complicate making reproducible hashes.
if that were the case nothing would work .. so it's bytes in - bytes out
Ok good, that's what I was expecting. I've unfortunately used some programs that even fairly recently depended on the system code page, so I'm always a little cautious.
Hi Max,
I realized later that I was doing something wrong. My fault here.
Glad that you've figured it out.
I thought that ConTeXt would output the same character encoding as in the source file when saving a buffer.
Yes, Hans confirmed that that is correct. Thanks, -- Max