Issue #1295 has been updated by Diego Suárez García. Of course, there goes the script: ========= #!/usr/bin/ruby require 'fileutils' require 'date' if ARGV.length != 2 puts "Uso: borradorSesiones.rb <DIRECTORIO> <NUMERO_DE_HORAS>" exit end Dir.foreach(ARGV[0]) do|x| f = File.new(ARGV[0]+"/"+x) File.delete(f.path) if f.mtime < (Time.now - (3600*ARGV[1].to_i)) and File.basename(f.path)=~/sess/ end ======== It's almost no more than a one-liner to quick-fix a little problem with a PHP writing too much files. It was in a hourly cron (the order was /path/borradorsesiones.rb /var/path_to_the_dir/ 3) ---------------------------------------- http://redmine.ruby-lang.org/issues/show/1295 ---------------------------------------- http://redmine.ruby-lang.org