Notify when tool is finished (#27459)
Now if a tool call finishes (or is blocked on confirmation) and the Zed window is not active, you get a notification popup. You can turn it off with a setting. <img width="420" alt="Screenshot 2025-03-25 at 5 19 25 PM" src="https://github.com/user-attachments/assets/bdf7b6b8-4428-4b46-8b09-e0be140f8a51" /> <img width="420 alt="Screenshot 2025-03-25 at 5 18 13 PM" src="https://github.com/user-attachments/assets/1325e7b8-cd5a-44b9-a82d-5db928ad3cfc" /> Release Notes: - N/A --------- Co-authored-by: Agus Zubiaga <hi@aguz.me> Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
This commit is contained in:
parent
a605b66ce1
commit
931a6d6f40
8 changed files with 216 additions and 3 deletions
|
@ -73,6 +73,7 @@ pub struct AssistantSettings {
|
|||
pub enable_experimental_live_diffs: bool,
|
||||
pub profiles: IndexMap<Arc<str>, AgentProfile>,
|
||||
pub always_allow_tool_actions: bool,
|
||||
pub notify_when_agent_waiting: bool,
|
||||
}
|
||||
|
||||
impl AssistantSettings {
|
||||
|
@ -175,6 +176,7 @@ impl AssistantSettingsContent {
|
|||
enable_experimental_live_diffs: None,
|
||||
profiles: None,
|
||||
always_allow_tool_actions: None,
|
||||
notify_when_agent_waiting: None,
|
||||
},
|
||||
VersionedAssistantSettingsContent::V2(settings) => settings.clone(),
|
||||
},
|
||||
|
@ -198,6 +200,7 @@ impl AssistantSettingsContent {
|
|||
enable_experimental_live_diffs: None,
|
||||
profiles: None,
|
||||
always_allow_tool_actions: None,
|
||||
notify_when_agent_waiting: None,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
@ -329,6 +332,7 @@ impl Default for VersionedAssistantSettingsContent {
|
|||
enable_experimental_live_diffs: None,
|
||||
profiles: None,
|
||||
always_allow_tool_actions: None,
|
||||
notify_when_agent_waiting: None,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
@ -372,6 +376,10 @@ pub struct AssistantSettingsContentV2 {
|
|||
///
|
||||
/// Default: false
|
||||
always_allow_tool_actions: Option<bool>,
|
||||
/// Whether to show a popup notification when the agent is waiting for user input.
|
||||
///
|
||||
/// Default: true
|
||||
notify_when_agent_waiting: Option<bool>,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, JsonSchema, PartialEq)]
|
||||
|
@ -519,6 +527,10 @@ impl Settings for AssistantSettings {
|
|||
&mut settings.always_allow_tool_actions,
|
||||
value.always_allow_tool_actions,
|
||||
);
|
||||
merge(
|
||||
&mut settings.notify_when_agent_waiting,
|
||||
value.notify_when_agent_waiting,
|
||||
);
|
||||
|
||||
if let Some(profiles) = value.profiles {
|
||||
settings
|
||||
|
@ -611,6 +623,7 @@ mod tests {
|
|||
enable_experimental_live_diffs: None,
|
||||
profiles: None,
|
||||
always_allow_tool_actions: None,
|
||||
notify_when_agent_waiting: None,
|
||||
}),
|
||||
)
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue