summaryrefslogtreecommitdiffstats
path: root/src/executor.rs
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2021-10-11 19:26:28 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2021-10-11 20:14:18 +0200
commitdfe446c63abf151b54ab1c9c371788078eda6912 (patch)
tree3bef2d9b818f57846823d6c79b0543fdb7b4c1e9 /src/executor.rs
parentdbafe13b0d5142acf7f8f30cb76c8adc5c179ce8 (diff)
downloadrebel-dfe446c63abf151b54ab1c9c371788078eda6912.tar
rebel-dfe446c63abf151b54ab1c9c371788078eda6912.zip
executor: sort and reformat summary output
Diffstat (limited to 'src/executor.rs')
-rw-r--r--src/executor.rs21
1 files changed, 16 insertions, 5 deletions
diff --git a/src/executor.rs b/src/executor.rs
index ec39d73..54543f3 100644
--- a/src/executor.rs
+++ b/src/executor.rs
@@ -355,12 +355,23 @@ impl<'ctx> Executor<'ctx> {
assert!(self.tasks_blocked.is_empty(), "No runnable tasks left");
- println!("Summary");
- for (task_ref, task) in &self.tasks_done {
+ println!();
+ println!("Summary:");
+
+ let mut tasks: Box<[_]> = self.tasks_done.iter().collect();
+ tasks.sort_by_cached_key(|(task, _)| format!("{:#}", task));
+ for (task_ref, task) in tasks.iter() {
println!();
- println!("{} ( {} )", task_ref, task.input_hash);
- for (output, hash) in &task.output.outputs {
- println!("-> {} ( {} )", output, hash);
+ println!("{:#}", task_ref);
+ println!(" input: {}", task.input_hash);
+ if let Some(hash) = task.output.layer {
+ println!(" layer: {}", hash);
+ }
+ if !task.output.outputs.is_empty() {
+ println!(" outputs:");
+ for (output, hash) in &task.output.outputs {
+ println!(" {}: {}", output, hash);
+ }
}
}
Ok(())