Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Cygwin perl... ftp... Windows line endings...

by cciulla (Friar)
on May 07, 2003 at 21:01 UTC ( [id://256381]=note: print w/replies, xml ) Need Help??


in reply to Cygwin perl... ftp... Windows line endings...

Can you use cygwin's dos2unix app?

If you have a number of these files, you can iterate over them using:

#!/usr/bin/perl $dirname = "."; opendir(DIR, $dirname) or die "can't opendir $dirname: $!"; while (defined($file = readdir(DIR))) { next if $file =~ /^\.\.?$/; system("dos2unix $file"); } closedir(DIR);

This'll try to convert directories, too, but you did say you were in a hurry.


I basically robbed The Perl Cookbook for more than 90% of this code. :)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://256381]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (4)
As of 2024-04-19 21:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found