40 41 42 43 44 45 46
# File 'lib/ccp/persistent/versioned.rb', line 40 def scan(dir) files = Dir.chdir(dir){ Dir["*"].grep(/^(\d+)\./).sort{|a,b| [a.to_i, File.mtime(a)] <=> [b.to_i, File.mtime(b)] } } end