Skip to content

Commit

Permalink
Merge pull request #36 from igbanam/enhancement/sort-db-migrate-statu…
Browse files Browse the repository at this point in the history
…s-by-date

Sort Migration Status
  • Loading branch information
eliasjpr authored Jul 31, 2019
2 parents 7d769c1 + c7dd047 commit 127307c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/micrate/cli.cr
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ module Micrate
DB.connect do |db|
puts "Applied At Migration"
puts "======================================="
Micrate.migration_status(db, migrations_path, migrations_table_suffix).each do |migration, migrated_at|
Micrate.migration_status(db, migrations_path, migrations_table_suffix).sort_by { |migration, migrated_at| migrated_at }.each do |migration, migrated_at|
ts = migrated_at.nil? ? "Pending" : migrated_at.to_s
puts "%-24s -- %s\n" % [ts, migration.name]
end
Expand Down

0 comments on commit 127307c

Please sign in to comment.