From: djberg96@... (Daniel Berger) Date: 2004-06-09T23:03:50+09:00 Subject: Re: strip DOS ^Ms? Dick Davies wrote in message news:<20040609094700.GA21180@lb.tenfour>... > Me again. I have chosen one of the crappiest websites on Gods > green Earth to scrape here.... > > For no good reason I have buttloads of '^M's all over the file > when I check it in vi. What would I feed gsub to strip them out? > Otherwise I'm looking at a very very long regex to yank out the > fields I need.... See "ptools", available on the RAA or at http://ruby-miscutils.sf.net. Look for the File.nl_convert method. :) Regards, Dan