Rename assistant2
to agent
(#27887)
This PR renames the `assistant2` crate to `agent`. Release Notes: - N/A
This commit is contained in:
parent
8e0f70f3c7
commit
dc83f1ad38
44 changed files with 97 additions and 100 deletions
|
@ -8,11 +8,11 @@ mod quick_action_bar;
|
|||
#[cfg(target_os = "windows")]
|
||||
pub(crate) mod windows_only_instance;
|
||||
|
||||
use agent::AssistantDiffToolbar;
|
||||
use anyhow::Context as _;
|
||||
pub use app_menus::*;
|
||||
use assets::Assets;
|
||||
use assistant_context_editor::AssistantPanelDelegate;
|
||||
use assistant2::AssistantDiffToolbar;
|
||||
use breadcrumbs::Breadcrumbs;
|
||||
use client::{ZED_URL_SCHEME, zed_urls};
|
||||
use collections::VecDeque;
|
||||
|
@ -466,12 +466,9 @@ fn initialize_panels(
|
|||
};
|
||||
|
||||
let (assistant_panel, assistant2_panel) = if is_assistant2_enabled {
|
||||
let assistant2_panel = assistant2::AssistantPanel::load(
|
||||
workspace_handle.clone(),
|
||||
prompt_builder,
|
||||
cx.clone(),
|
||||
)
|
||||
.await?;
|
||||
let assistant2_panel =
|
||||
agent::AssistantPanel::load(workspace_handle.clone(), prompt_builder, cx.clone())
|
||||
.await?;
|
||||
|
||||
(None, Some(assistant2_panel))
|
||||
} else {
|
||||
|
@ -499,16 +496,16 @@ fn initialize_panels(
|
|||
// We need to do this here instead of within the individual `init`
|
||||
// functions so that we only register the actions once.
|
||||
//
|
||||
// Once we ship `assistant2` we can push this back down into `assistant2::assistant_panel::init`.
|
||||
// Once we ship `assistant2` we can push this back down into `agent::assistant_panel::init`.
|
||||
if is_assistant2_enabled {
|
||||
<dyn AssistantPanelDelegate>::set_global(
|
||||
Arc::new(assistant2::ConcreteAssistantPanelDelegate),
|
||||
Arc::new(agent::ConcreteAssistantPanelDelegate),
|
||||
cx,
|
||||
);
|
||||
|
||||
workspace
|
||||
.register_action(assistant2::AssistantPanel::toggle_focus)
|
||||
.register_action(assistant2::InlineAssistant::inline_assist);
|
||||
.register_action(agent::AssistantPanel::toggle_focus)
|
||||
.register_action(agent::InlineAssistant::inline_assist);
|
||||
} else {
|
||||
<dyn AssistantPanelDelegate>::set_global(
|
||||
Arc::new(assistant::assistant_panel::ConcreteAssistantPanelDelegate),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue