Typo in buff-ini.lua
Hi Hans, In buff-ini.lua, line 73 should be return concat(t,separator or "\n") -- AM: was \r Otherwise, the following gives a wrong output: \startbuffer[one] This is one \stopbuffer \startbuffer[two] This is two \stopbuffer \ctxcommand{savebuffer({"one", "two"}, "test.tmp")} \end Aditya
On Sat, 16 Apr 2011, Aditya Mahajan wrote:
Hi Hans,
In buff-ini.lua, line 73 should be
return concat(t,separator or "\n") -- AM: was \r
Actually, I am not sure if this is a bug or not. I was testing by "cat filename" and was only seeing the last line. Opening the file on editor shows that the file contains This is one^MThis is two So, it is just a matter of how the OS handles line breaks. Aditya
On 16-4-2011 8:24, Aditya Mahajan wrote:
On Sat, 16 Apr 2011, Aditya Mahajan wrote:
Hi Hans,
In buff-ini.lua, line 73 should be
return concat(t,separator or "\n") -- AM: was \r
Actually, I am not sure if this is a bug or not. I was testing by "cat filename" and was only seeing the last line. Opening the file on editor shows that the file contains
This is one^MThis is two
So, it is just a matter of how the OS handles line breaks.
it's more tricky ... tex normalizes crlf into its own line ending (^^M) newlinechar -> used when writing (ascii 10 by default) endofline -> ^^M (13) and all over the mkiv/lua code you will find traces of this ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
participants (2)
-
Aditya Mahajan
-
Hans Hagen