This breaks setting `{"scrollbar": {"show":"never"}}` Release Notes: - N/A
This commit is contained in:
parent
3b37db4140
commit
4d26f83d23
49 changed files with 686 additions and 833 deletions
|
@ -6,25 +6,18 @@ use serde::{Deserialize, Serialize};
|
|||
use settings::{Settings, SettingsSources};
|
||||
use std::sync::Arc;
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug, Clone, JsonSchema)]
|
||||
#[serde(default)]
|
||||
#[derive(Deserialize, Serialize, Debug, Default, Clone, JsonSchema)]
|
||||
pub struct ExtensionSettings {
|
||||
/// The extensions that should be automatically installed by Zed.
|
||||
///
|
||||
/// This is used to make functionality provided by extensions (e.g., language support)
|
||||
/// available out-of-the-box.
|
||||
#[serde(default)]
|
||||
pub auto_install_extensions: HashMap<Arc<str>, bool>,
|
||||
#[serde(default)]
|
||||
pub auto_update_extensions: HashMap<Arc<str>, bool>,
|
||||
}
|
||||
|
||||
impl Default for ExtensionSettings {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
auto_install_extensions: HashMap::from_iter([("html".into(), true)]),
|
||||
auto_update_extensions: Default::default(),
|
||||
}
|
||||
}
|
||||
}
|
||||
impl ExtensionSettings {
|
||||
/// Returns whether the given extension should be auto-installed.
|
||||
pub fn should_auto_install(&self, extension_id: &str) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue