David Marko
2006-Sep-15 07:38 UTC
Mostly Ruby question: How to change file modification time?
Does anyone know how to change file modification time with Ruby? I found how to get last modification time, but dont know how to change it. Thanks, David -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
Heikki
2006-Sep-15 09:05 UTC
Re: Mostly Ruby question: How to change file modification time?
http://www.ruby-doc.org/core/classes/File.html#M000013 or http://www.ruby-doc.org/core/classes/FileUtils.html#M001731 -- Heikki --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
cesium62
2006-Sep-15 09:08 UTC
Re: Mostly Ruby question: How to change file modification time?
http://www.ruby-doc.org/stdlib/ says " touch(list, options = {}) Options: noop verbose Updates modification time (mtime) and access time (atime) of file(s) in list. Files are created if they don''t exist. FileUtils.touch ''timestamp'' FileUtils.touch Dir.glob(''*.c''); system ''make'' [Source] " --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---