UX: discourse restore -- sort by date

This commit is contained in:
Jay Pfaffman 2017-10-05 15:20:14 -07:00
parent 0c84352386
commit e61edfd13a
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ class DiscourseCLI < Thor
if !filename
puts "You must provide a filename to restore. Did you mean one of the following?\n\n"
Dir["public/backups/default/*"].each do |f|
Dir["public/backups/default/*"].sort_by { |filename| File.mtime(filename) }.reverse.each do |f|
puts "#{discourse} restore #{File.basename(f)}"
end