mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 18:30:26 -06:00
UX: discourse restore -- sort by date
This commit is contained in:
parent
0c84352386
commit
e61edfd13a
@ -96,7 +96,7 @@ class DiscourseCLI < Thor
|
|||||||
if !filename
|
if !filename
|
||||||
puts "You must provide a filename to restore. Did you mean one of the following?\n\n"
|
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)}"
|
puts "#{discourse} restore #{File.basename(f)}"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user