[Newbie] Generated files don't use Windows end-of-lines

I’m trying to use Rails on Windows 2000. I’m running into an immediate
problem in that all the files generated by Rails use the UNIX
end-of-line convention instead of the Windows end-of-line convention. A
non-compliant end-of-line convention will break any number of tools I
may wish to use to manage these files.

Is there a way to get Rails to emit Windows-compliant end-of-lines?

Thanks.

Details follow…

I used the one-click installer for Ruby on Windows. Here’s the version
it reports:

ruby 1.8.4 (2005-12-24) [i386-mswin32]

I then did “gem install rails --include-dependencies”. And, here’s the
version it reports:

Rails 1.1.4

All looked good. Now, working my way through the Agile Web D.
with Rails book, I did:

rails demo
cd demo
ruby script\generate controller Say

Which generated a bunch of directories/files, but all of the files use
the UNIX end-of-line convention.

Jeff:
Forgive me if I come across rather rude; that is not my intent.

The best way to handle that is to use an editor or IDE that supports
different encoding modes. I don’t know what tools you use, but I know
Eclipse + RDT, RadRails, Notepad++, ArachnoRuby, Komodo, Dreamweaver,
and
countless other tools don’t have a problem reading the Unix newlines. It
sounds like your toolset is “non-compliant” and not Rails.

In fact, if you ever need to deploy on Linux, using an editor that will
handle these newlines properly will be a huge timesaver.

I’ve spent a good deal of time developing and deploying on Windows and
have
had very few issues. The newline issue is easily handled by using an
editor
that can not only interpret but also write the proper newline…

Good luck!

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs