Mark Panasci wrote:
I'm using active state perl on win2k box, and need the script to create zero byte length text files, like the touch command does in Unix. I've been searching around for a couple of days now and haven't found anything. Surely there's an easy way to do this? Thanks!

Just open the file in write mode and then close it without writing any data to the file.


open ZERO, '>', 'somefile' or die "Cannot create 'somefile' $!";
close ZERO;



John
--
use Perl;
program
fulfillment

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to