28 Feb
2006
28 Feb
'06
4:22 p.m.
Taco Hoekwater wrote:
Setting \endlinechar to -1 temporarily is a possibility, another is writing a percent sign to the end of the line, yet another is ending the written line with \relax (or a similar space-gobbling command), and finally changing the catcode of the current \endlinechar to 9 (ignored) also works.
Here is a file demonstrating all four: \starttext % 1 \immediate\write18{echo -n X >bla1.tex} X{\endlinechar=-1 \input bla1 }X % 2 \immediate\write18{echo -n X\letterpercent >bla2.tex} X\input bla2 X % 3 \immediate \write18 {echo -n X\letterbackslash\letterbackslash relax >bla3.tex} X\input bla3 X % 4 \immediate\write18{echo -n X >bla4.tex} X{\catcode`\^^M=9 \input bla4 }X \stoptext