From: PeJaMa@... (Marcus Heyking) Date: 2004-03-17T01:54:33+09:00 Subject: ruby 1.8.1/cygwin: Writing text files (dos mode) broken? I was recently running some tests before switching to ruby 1.8.1 on cygwin. I found one problem that currently keeps me from installing ruby 1.8.1: When writing text files they end up as unix files even though I explicitly told setup.exe to use dos mode: f = File.new("test.txt","w") f.puts("Where \n is the CR?") f.close Running above script on ruby 1.8.1 will create test.txt with only 0x0a (LF) as line delimiter. When using ruby 1.6.8 this correctly creates a dos-like text file (CR+LF) My ruby app (a build engine) creates c/cpp headers and resource files to be used by cl.exe and friends - and some of them won't accept unix style files. Maybe someone could verify/comment on that? Did I miss something here? IMHO line ending conversion should still be transparent to ruby scripts? ps. Actually I think this is caused by io.c:line 4087 where cygwin_internal() is used to unconditionally set file IO to binmode!?