I am not sure, if this will help with your task, but if i want to  avoid that 
the os replaces the line breaks with it´s default i am writing a binary file 
instead of a text file.  So in your case you would open the file for "binary 
write".

Regards,
Matthias

Matthias Rebbe

free tools for Livecoders:
InstaMaker <https://instamaker.dermattes.de/>
WinSignMaker Mac <https://winsignhelper.dermattes.de/>

> Am 30.10.2019 um 22:28 schrieb Dr. Hawkins via use-livecode 
> <[email protected] <mailto:[email protected]>>:
> 
> 
> I’ve tried every combination of cr, lf, and crlf, but whenever I assemble 
> into a file, I get something that neither the OSX terminal or vim recognizes 
> as having lf in it
> 
> I build a set of commands in mrgCmds, appending cr as I go, but I get a bunch 
> of ^M in the otherwise uninterrupted stream with vi and less, while cat shows 
> me the last line (presumably, as it keeps writing it over.
> 
> The code in question is
> 
> put "outFil=open(theOutPdf, 'wb')" & cr after mrgCmds
> 
> put "outFil.write(theOutPdf)" & cr after mrgCmds
> 
> put "quit" & cr after mrgCmds
> 
> replace cr with crlf in mrgCmds
> 
> open file fldr & "/theCmds.py" for write
> 
> write mrgCmds to file fldr & "/theCmds.py"
> 
> close file fldr & "/theCmds.py"
> 
> 
> please, someone help, before the termcap flashbacks tern me into a quivering 
> blob of fear!
> — 
> Richard E. Hawkins, Esq.
> The Hawkins Law Firm
> 3430 E. Flamingo Rd.
> Suite 232
> Las Vegas, NV  89121
> (702) 508-8462
> 
> _______________________________________________
> use-livecode mailing list
> [email protected] <mailto:[email protected]>
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to