Cygwin setup on XP/Vista (UNIX/DOS compatibilty question)

Steve Richmond srichman69@hotmail.com
Fri Sep 21 23:40:00 GMT 2007


I have a problem with running bash scripts and UNIX/Win compatibility.
I have 3 computers: a Windows ME PC (PC1), a Windows XP (PC2) and a
Windows Vista (PC3).

On PC1, I have an old version of Cygwin and bash (3.00.16.14 i686-pc-cygwin).
All my scripts have a .TXT suffix, so I can edit with Vim editor.  The scripts
generate .CSV (comma separated value) files, so I can examine and print with
Excel as well as edit with Vim.  I don't recall when I initially set it up
whether I set the Cygwin mode to be UNIX or DOS compatible for CR/LF.

On PC2 and PC3, I have an up-to-date version of Cygwin and bash
(3.2.5(7) i686-pc-cygwin).

However it behaves differently.  After I install it using UNIX, bash scripts
fail with '\r' errors, meaning it can't find the CR. So after I re-installed
to be DOS compatible for CR/LF, the bash scripts execute successfully, but
the resulting .CSV file has a '^M' added to each line.  Subsequent
manipulation with paste (as an example) fail because of the extra '^M'.

I read the FAQs about the different behavior with UNIX and DOS, but I must
have missed something because it should work one way or the other.

What do you I have to do with the setup to get the earlier behavior?



_________________________________________________________________
More photos; more messages; more whatever – Get MORE with Windows Live™ Hotmail®. NOW with 5GB storage.
http://imagine-windowslive.com/hotmail/?locale=en-us&ocid=TXT_TAGHM_migration_HM_mini_5G_0907

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list