On Dec 30, 3:02=A0am, Alain Matthes <al... / pomme.com> wrote:
> On 2010-12-29 22:05:23 +0100, w_a_x_man said:
>
> > require 'ftools'
>
> > HEADER =3D '\input{Vorspann.ltx}
>
> > \begin{document}
>
> > %s
> > \end{document}
> > '
>
> > File.makedirs( "new" )
>
> > Dir[ "*.tex" ].each{|fname|
> > =A0 =A0text =3D IO.read( fname )
> > =A0 =A0text2 =3D HEADER % text
> > =A0 =A0File.open( "new/" + fname, "wb" ){|fh|
> > =A0 =A0 fh.print text2
> > =A0 }
> > }
>
> Hello,
>
> Very fine! I try with success your code.
>
> A question : =A0with python, I've a the line =A0 =A0# -*- coding: utf-8 -=
*-
> Do Ruby works without problem =A0with utf8 encoding ?

I don't know much about utf8.

> (I work with Ruby 1.8.7 on OS X.)
>
> In my case, =A0input files are in utf8 and I notice =A0output files
> =A0are also in utf8 with your code.