Created
May 11, 2013 17:07
-
-
Save dalang/5560625 to your computer and use it in GitHub Desktop.
copy data from one file to another file line for line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
open(IFILE, "<index.html"); | |
open(FILE, ">_tmpfile.txt"); | |
while(<IFILE>) { | |
chomp(); | |
syswrite(FILE, $_); | |
syswrite(FILE, "\n"); | |
} | |
close(FILE); | |
close(IFILE); | |
<>; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment