From fc68f9b6ae5548c056151f8c297856281cce6d1f Mon Sep 17 00:00:00 2001 From: Dmitriy Pleshevskiy Date: Sat, 6 Feb 2021 01:39:12 +0300 Subject: [PATCH] refac: revert applied migrations for list ... command and visually separated applied and pending migrations --- migra-cli/src/main.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/migra-cli/src/main.rs b/migra-cli/src/main.rs index 000764d..4bb97ea 100644 --- a/migra-cli/src/main.rs +++ b/migra-cli/src/main.rs @@ -89,9 +89,12 @@ fn main() -> Result<(), Box> { } else { applied_migrations .iter() + .rev() .for_each(|name| println!("{}", name)); } + println!(); + let pending_migrations = config.migrations()? .into_iter() .filter(|m| !applied_migrations.contains(m.name()))