in reply to Re^2: Making tmp copies of files
in thread Making tmp copies of files
BTW, make copies of the original before overwriting them. The last thing you want to do is blow them all away and realize you don't have backups.# For foo.htm => foo.htm.tmp opendir( HTMLSTORIES, "$html_dir") || die "HTML files do not exist: $! +"; @FigureArray = grep{/\.htm$/} readdir ( HTMLSTORIES ); foreach $figfile (@FigureArray) { copy ($figfile, "$figfile.tmp") or die "Can not make temporary cop +y of file [$figfile]: $!"; }
|
|---|