Automate settings registration (#42238)
Release Notes: - N/A --------- Co-authored-by: Nia <nia@zed.dev>
This commit is contained in:
@@ -409,7 +409,7 @@ pub fn main() {
|
||||
handle_settings_changed,
|
||||
);
|
||||
handle_keymap_file_changes(user_keymap_file_rx, cx);
|
||||
client::init_settings(cx);
|
||||
|
||||
let user_agent = format!(
|
||||
"Zed/{} ({}; {})",
|
||||
AppVersion::global(cx),
|
||||
@@ -468,7 +468,6 @@ pub fn main() {
|
||||
let node_runtime = NodeRuntime::new(client.http_client(), Some(shell_env_loaded_rx), rx);
|
||||
|
||||
debug_adapter_extension::init(extension_host_proxy.clone(), cx);
|
||||
language::init(cx);
|
||||
languages::init(languages.clone(), fs.clone(), node_runtime.clone(), cx);
|
||||
let user_store = cx.new(|cx| UserStore::new(client.clone(), cx));
|
||||
let workspace_store = cx.new(|cx| WorkspaceStore::new(client.clone(), cx));
|
||||
@@ -573,7 +572,6 @@ pub fn main() {
|
||||
supermaven::init(app_state.client.clone(), cx);
|
||||
language_model::init(app_state.client.clone(), cx);
|
||||
language_models::init(app_state.user_store.clone(), app_state.client.clone(), cx);
|
||||
agent_settings::init(cx);
|
||||
acp_tools::init(cx);
|
||||
zeta2_tools::init(cx);
|
||||
web_search::init(cx);
|
||||
|
||||
@@ -1408,9 +1408,6 @@ pub fn handle_keymap_file_changes(
|
||||
mut user_keymap_file_rx: mpsc::UnboundedReceiver<String>,
|
||||
cx: &mut App,
|
||||
) {
|
||||
BaseKeymap::register(cx);
|
||||
vim_mode_setting::init(cx);
|
||||
|
||||
let (base_keymap_tx, mut base_keymap_rx) = mpsc::unbounded();
|
||||
let (keyboard_layout_tx, mut keyboard_layout_rx) = mpsc::unbounded();
|
||||
let mut old_base_keymap = *BaseKeymap::get_global(cx);
|
||||
@@ -4331,10 +4328,8 @@ mod tests {
|
||||
|
||||
theme::init(theme::LoadThemes::JustBase, cx);
|
||||
client::init(&app_state.client, cx);
|
||||
language::init(cx);
|
||||
workspace::init(app_state.clone(), cx);
|
||||
onboarding::init(cx);
|
||||
Project::init_settings(cx);
|
||||
app_state
|
||||
})
|
||||
}
|
||||
@@ -4797,21 +4792,17 @@ mod tests {
|
||||
|
||||
let state = Arc::get_mut(&mut app_state).unwrap();
|
||||
state.build_window_options = build_window_options;
|
||||
|
||||
app_state.languages.add(markdown_language());
|
||||
|
||||
gpui_tokio::init(cx);
|
||||
vim_mode_setting::init(cx);
|
||||
theme::init(theme::LoadThemes::JustBase, cx);
|
||||
audio::init(cx);
|
||||
channel::init(&app_state.client, app_state.user_store.clone(), cx);
|
||||
call::init(app_state.client.clone(), app_state.user_store.clone(), cx);
|
||||
notifications::init(app_state.client.clone(), app_state.user_store.clone(), cx);
|
||||
workspace::init(app_state.clone(), cx);
|
||||
Project::init_settings(cx);
|
||||
release_channel::init(SemanticVersion::default(), cx);
|
||||
command_palette::init(cx);
|
||||
language::init(cx);
|
||||
editor::init(cx);
|
||||
collab_ui::init(&app_state, cx);
|
||||
git_ui::init(cx);
|
||||
|
||||
@@ -665,9 +665,6 @@ mod tests {
|
||||
#[gpui::test]
|
||||
fn test_parse_ssh_url(cx: &mut TestAppContext) {
|
||||
let _app_state = init_test(cx);
|
||||
cx.update(|cx| {
|
||||
SshSettings::register(cx);
|
||||
});
|
||||
let request = cx.update(|cx| {
|
||||
OpenRequest::parse(
|
||||
RawOpenRequest {
|
||||
|
||||
Reference in New Issue
Block a user