From: "Tim Van Holder" Subject: Re: UTOD & DTOU Newsgroups: comp.os.msdos.djgpp Organization: Falcon Software NV Message-ID: <20001109.133204.1139901474.9880@falconsoft.be> References: <3A08062D DOT 1A866F04 AT lps DOT u-psud DOT fr> User-Agent: Pan/0.9.1 (Unix) X-No-Productlinks: Yes Lines: 25 Date: Thu, 09 Nov 2000 12:32:41 GMT NNTP-Posting-Host: 195.207.71.6 X-Complaints-To: abuse AT Belgium DOT EU DOT net X-Trace: nreader1.kpnqwest.net 973773161 195.207.71.6 (Thu, 09 Nov 2000 13:32:41 MET) NNTP-Posting-Date: Thu, 09 Nov 2000 13:32:41 MET To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com In a burst of inspiration, "Daniel Taupin" wrote this on <3A08062D DOT 1A866F04 AT lps DOT u-psud DOT fr>: Aren't there unix2dos and dos2unix programs available for Linux? I dimly remeber those from my HP-UX days. They're filters, so usage won't be exactly the same as dtou/utod though. Alternatively, use recode. Version 3.5 and above support 'surfaces', which will do exactly what we want. recode /data../cr-lf your-file-here does exactly what utod does, while recode /cr-lf../data your-file-here is a viable replacement for dtou. Additionally, recode can also act like a filter. RPMs for recode are available as part of the libc6 contribs, so there should be no problem getting it (or you can just get the sources from ftp.gnu.org and compile it yourself). In a pinch, you could use tr -d '\r' for dtou, but that would kill CR's that occur in the middle of a line. -- Tim Van Holder - Falcon Software NV =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Fight spam - go to http://www.politik-digital.de/spam/