mirror of
https://github.com/jparkerweb/plan2code.git
synced 2026-12-05 16:15:41 -08:00
Run the quit cleanup on a plain kill, Ctrl+C and a closing terminal
AI Assisted
This commit is contained in:
1 parent
6a93395148
commit
8c028c1ce0
7 files changed
+458
-3
No files matched your search
@@ -11,6 +11,7 @@ use std::thread;
|
||||
use serde::Serialize;
|
||||
|
||||
use crate::agents::{agent_launch_spec, Agent, PermissionMode};
|
||||
use crate::log;
|
||||
use crate::pty_host::{PtyHost, StartOptions};
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq, Serialize)]
|
||||
@@ -734,7 +735,7 @@ impl Shared {
|
||||
// the log, since the bar's reason is gone once a new agent starts.
|
||||
if let Some((choice, _)) = &inner.last_start {
|
||||
if let Some(line) = exit_log_line(choice.kind.id(), &reason) {
|
||||
eprintln!("{line}");
|
||||
log::line(&line);
|
||||
}
|
||||
}
|
||||
inner.state = AgentState::Ended { reason };
|
||||
|
||||
Reference in new issue
Block a user