Revert deprecate code actions on format (#40409)
Closes #40334 This reverts the change made in #39983, and includes a replacement migration that will transform formatter settings values consisting of only `code_action` format steps into the previously deprecated `code_actions_on_format` in an attempt to restore the behavior to what it was before the migration that deprecated `code_actions_on_format`. This PR will result in a modified order in the `code_actions_on_format` setting if it existed, however the decision was made to explicitly ignore this for now, as this PR is primarily targeting users who have already had the deprecation migration run, and no longer have the `code_actions_on_format` key Release Notes: - Fixed an issue with a settings migration that deprecated the `code_actions_on_format` setting. The `code_actions_on_format` setting has been un-deprecated, and affected users will have the bad migration rolled back with an updated migration --------- Co-authored-by: Cole Miller <cole@zed.dev> Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com> Co-authored-by: HactarCE <6060305+HactarCE@users.noreply.github.com>
This commit is contained in:
co-authored by
Cole Miller
Mikayla Maki
HactarCE
parent
04f0805502
commit
81425bef72
@@ -5437,6 +5437,27 @@ fn language_settings_data() -> Vec<SettingsPageItem> {
|
||||
metadata: None,
|
||||
files: USER | LOCAL,
|
||||
}),
|
||||
SettingsPageItem::SettingItem(SettingItem {
|
||||
title: "Code Actions On Format",
|
||||
description: "Additional Code Actions To Run When Formatting",
|
||||
field: Box::new(
|
||||
SettingField {
|
||||
pick: |settings_content| {
|
||||
language_settings_field(settings_content, |language| {
|
||||
&language.code_actions_on_format
|
||||
})
|
||||
},
|
||||
pick_mut: |settings_content| {
|
||||
language_settings_field_mut(settings_content, |language| {
|
||||
&mut language.code_actions_on_format
|
||||
})
|
||||
},
|
||||
}
|
||||
.unimplemented(),
|
||||
),
|
||||
metadata: None,
|
||||
files: USER | LOCAL,
|
||||
}),
|
||||
SettingsPageItem::SectionHeader("Autoclose"),
|
||||
SettingsPageItem::SettingItem(SettingItem {
|
||||
title: "Use Autoclose",
|
||||
|
||||
Reference in New Issue
Block a user