From a6537e4dba0eeb175c80df37869c52238be600b8 Mon Sep 17 00:00:00 2001 From: "Dhanji R. Prasanna" Date: Tue, 2 Dec 2025 13:48:05 +1100 Subject: [PATCH] todo_write outputs entire list --- crates/g3-core/src/lib.rs | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/crates/g3-core/src/lib.rs b/crates/g3-core/src/lib.rs index 8d9587d..cadf921 100644 --- a/crates/g3-core/src/lib.rs +++ b/crates/g3-core/src/lib.rs @@ -4735,6 +4735,11 @@ impl Agent { if content.trim().is_empty() { Ok("📝 TODO list is empty".to_string()) } else { + // Print the TODO content to the console + self.ui_writer.print_context_status("📝 TODO list:"); + for line in content.lines() { + self.ui_writer.print_tool_output_line(line); + } Ok(format!("📝 TODO list:\n{}", content)) } } @@ -4788,10 +4793,15 @@ impl Agent { // Also update in-memory content to stay in sync let mut todo = self.todo_content.write().await; *todo = content_str.to_string(); - Ok(format!( - "✅ TODO list updated ({} chars) and saved to todo.g3.md", + // Print the TODO content to the console + self.ui_writer.print_context_status(&format!( + "✅ TODO list updated ({} chars) and saved to todo.g3.md:", char_count - )) + )); + for line in content_str.lines() { + self.ui_writer.print_tool_output_line(line); + } + Ok(format!("✅ TODO list updated ({} chars) and saved to todo.g3.md:\n{}", char_count, content_str)) } Err(e) => Ok(format!("❌ Failed to write todo.g3.md: {}", e)), }