Here’s how to touch a file using Ruby, easy as 1-2-3:
File.utime(access_time, mod_time, filename)
Tags: Ruby
1 Michael Xavier // Apr 30, 2010 at 10:21 am
Any reason why this is preferable to FileUtils.touch?
Name
Mail
Website
1 response so far ↓
1 Michael Xavier // Apr 30, 2010 at 10:21 am
Any reason why this is preferable to FileUtils.touch?
Leave a Comment