feat(schema): deny unknown keys (#4270)

This commit is contained in:
David Knaack 2022-09-09 14:59:38 +02:00 committed by GitHub
parent 06281c268d
commit b5d3d8fcf3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
83 changed files with 560 additions and 162 deletions

View File

@ -1546,6 +1546,7 @@
"type": "boolean" "type": "boolean"
} }
}, },
"additionalProperties": false,
"definitions": { "definitions": {
"AwsConfig": { "AwsConfig": {
"title": "AWS", "title": "AWS",
@ -1598,7 +1599,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"AzureConfig": { "AzureConfig": {
"type": "object", "type": "object",
@ -1619,7 +1621,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"BatteryConfig": { "BatteryConfig": {
"type": "object", "type": "object",
@ -1666,7 +1669,8 @@
"default": "[$symbol$percentage]($style) ", "default": "[$symbol$percentage]($style) ",
"type": "string" "type": "string"
} }
} },
"additionalProperties": false
}, },
"BatteryDisplayConfig": { "BatteryDisplayConfig": {
"type": "object", "type": "object",
@ -1694,7 +1698,8 @@
"null" "null"
] ]
} }
} },
"additionalProperties": false
}, },
"BufConfig": { "BufConfig": {
"type": "object", "type": "object",
@ -1744,7 +1749,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"BunConfig": { "BunConfig": {
"type": "object", "type": "object",
@ -1793,7 +1799,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"CConfig": { "CConfig": {
"type": "object", "type": "object",
@ -1865,7 +1872,8 @@
} }
} }
} }
} },
"additionalProperties": false
}, },
"CharacterConfig": { "CharacterConfig": {
"type": "object", "type": "object",
@ -1902,7 +1910,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"CMakeConfig": { "CMakeConfig": {
"type": "object", "type": "object",
@ -1951,7 +1960,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"CmdDurationConfig": { "CmdDurationConfig": {
"type": "object", "type": "object",
@ -1994,7 +2004,8 @@
"format": "uint32", "format": "uint32",
"minimum": 0.0 "minimum": 0.0
} }
} },
"additionalProperties": false
}, },
"CobolConfig": { "CobolConfig": {
"type": "object", "type": "object",
@ -2045,7 +2056,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"CondaConfig": { "CondaConfig": {
"type": "object", "type": "object",
@ -2076,7 +2088,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"ContainerConfig": { "ContainerConfig": {
"type": "object", "type": "object",
@ -2097,7 +2110,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"CrystalConfig": { "CrystalConfig": {
"type": "object", "type": "object",
@ -2147,7 +2161,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"DamlConfig": { "DamlConfig": {
"type": "object", "type": "object",
@ -2195,7 +2210,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"DartConfig": { "DartConfig": {
"type": "object", "type": "object",
@ -2249,7 +2265,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"DenoConfig": { "DenoConfig": {
"type": "object", "type": "object",
@ -2302,7 +2319,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"DirectoryConfig": { "DirectoryConfig": {
"type": "object", "type": "object",
@ -2375,7 +2393,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"DockerContextConfig": { "DockerContextConfig": {
"type": "object", "type": "object",
@ -2425,7 +2444,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"DotnetConfig": { "DotnetConfig": {
"type": "object", "type": "object",
@ -2485,7 +2505,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"ElixirConfig": { "ElixirConfig": {
"type": "object", "type": "object",
@ -2533,7 +2554,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"ElmConfig": { "ElmConfig": {
"type": "object", "type": "object",
@ -2587,7 +2609,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"EnvVarConfig": { "EnvVarConfig": {
"type": "object", "type": "object",
@ -2620,7 +2643,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"ErlangConfig": { "ErlangConfig": {
"type": "object", "type": "object",
@ -2669,7 +2693,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"FillConfig": { "FillConfig": {
"type": "object", "type": "object",
@ -2686,7 +2711,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"GcloudConfig": { "GcloudConfig": {
"type": "object", "type": "object",
@ -2721,7 +2747,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"GitBranchConfig": { "GitBranchConfig": {
"type": "object", "type": "object",
@ -2766,7 +2793,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"GitCommitConfig": { "GitCommitConfig": {
"type": "object", "type": "object",
@ -2807,7 +2835,8 @@
"format": "uint", "format": "uint",
"minimum": 0.0 "minimum": 0.0
} }
} },
"additionalProperties": false
}, },
"GitMetricsConfig": { "GitMetricsConfig": {
"type": "object", "type": "object",
@ -2832,7 +2861,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"GitStateConfig": { "GitStateConfig": {
"type": "object", "type": "object",
@ -2877,7 +2907,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"GitStatusConfig": { "GitStatusConfig": {
"type": "object", "type": "object",
@ -2948,7 +2979,8 @@
"null" "null"
] ]
} }
} },
"additionalProperties": false
}, },
"GoConfig": { "GoConfig": {
"type": "object", "type": "object",
@ -3006,7 +3038,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"HaskellConfig": { "HaskellConfig": {
"type": "object", "type": "object",
@ -3059,7 +3092,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"HelmConfig": { "HelmConfig": {
"type": "object", "type": "object",
@ -3108,7 +3142,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"HgBranchConfig": { "HgBranchConfig": {
"type": "object", "type": "object",
@ -3138,7 +3173,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"HostnameConfig": { "HostnameConfig": {
"type": "object", "type": "object",
@ -3167,7 +3203,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"JavaConfig": { "JavaConfig": {
"type": "object", "type": "object",
@ -3228,7 +3265,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"JobsConfig": { "JobsConfig": {
"type": "object", "type": "object",
@ -3264,7 +3302,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"JuliaConfig": { "JuliaConfig": {
"type": "object", "type": "object",
@ -3315,7 +3354,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"KotlinConfig": { "KotlinConfig": {
"type": "object", "type": "object",
@ -3368,7 +3408,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"KubernetesConfig": { "KubernetesConfig": {
"type": "object", "type": "object",
@ -3424,7 +3465,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"LineBreakConfig": { "LineBreakConfig": {
"type": "object", "type": "object",
@ -3433,7 +3475,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"LocalipConfig": { "LocalipConfig": {
"type": "object", "type": "object",
@ -3454,7 +3497,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"LuaConfig": { "LuaConfig": {
"type": "object", "type": "object",
@ -3510,7 +3554,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"MemoryConfig": { "MemoryConfig": {
"type": "object", "type": "object",
@ -3536,7 +3581,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"NimConfig": { "NimConfig": {
"type": "object", "type": "object",
@ -3588,7 +3634,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"NixShellConfig": { "NixShellConfig": {
"type": "object", "type": "object",
@ -3617,7 +3664,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"NodejsConfig": { "NodejsConfig": {
"type": "object", "type": "object",
@ -3680,7 +3728,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"OCamlConfig": { "OCamlConfig": {
"type": "object", "type": "object",
@ -3749,7 +3798,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"OspConfig": { "OspConfig": {
"type": "object", "type": "object",
@ -3770,7 +3820,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"PackageConfig": { "PackageConfig": {
"type": "object", "type": "object",
@ -3799,7 +3850,8 @@
"default": "v${raw}", "default": "v${raw}",
"type": "string" "type": "string"
} }
} },
"additionalProperties": false
}, },
"PerlConfig": { "PerlConfig": {
"type": "object", "type": "object",
@ -3857,7 +3909,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"PhpConfig": { "PhpConfig": {
"type": "object", "type": "object",
@ -3908,7 +3961,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"PulumiConfig": { "PulumiConfig": {
"type": "object", "type": "object",
@ -3937,7 +3991,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"PureScriptConfig": { "PureScriptConfig": {
"type": "object", "type": "object",
@ -3987,7 +4042,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"PythonConfig": { "PythonConfig": {
"type": "object", "type": "object",
@ -4063,7 +4119,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"Either_for_String_and_Array_of_String": { "Either_for_String_and_Array_of_String": {
"anyOf": [ "anyOf": [
@ -4130,7 +4187,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"RedConfig": { "RedConfig": {
"type": "object", "type": "object",
@ -4179,7 +4237,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"RLangConfig": { "RLangConfig": {
"type": "object", "type": "object",
@ -4235,7 +4294,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"RubyConfig": { "RubyConfig": {
"type": "object", "type": "object",
@ -4296,7 +4356,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"RustConfig": { "RustConfig": {
"type": "object", "type": "object",
@ -4346,7 +4407,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"ScalaConfig": { "ScalaConfig": {
"type": "object", "type": "object",
@ -4401,7 +4463,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"ShellConfig": { "ShellConfig": {
"type": "object", "type": "object",
@ -4462,7 +4525,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"ShLvlConfig": { "ShLvlConfig": {
"type": "object", "type": "object",
@ -4492,7 +4556,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"SingularityConfig": { "SingularityConfig": {
"type": "object", "type": "object",
@ -4513,7 +4578,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"SpackConfig": { "SpackConfig": {
"type": "object", "type": "object",
@ -4540,7 +4606,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"StatusConfig": { "StatusConfig": {
"type": "object", "type": "object",
@ -4607,7 +4674,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"SudoConfig": { "SudoConfig": {
"type": "object", "type": "object",
@ -4632,7 +4700,8 @@
"default": true, "default": true,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"SwiftConfig": { "SwiftConfig": {
"type": "object", "type": "object",
@ -4682,7 +4751,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"TerraformConfig": { "TerraformConfig": {
"type": "object", "type": "object",
@ -4734,7 +4804,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"TimeConfig": { "TimeConfig": {
"type": "object", "type": "object",
@ -4769,7 +4840,8 @@
"default": "-", "default": "-",
"type": "string" "type": "string"
} }
} },
"additionalProperties": false
}, },
"UsernameConfig": { "UsernameConfig": {
"type": "object", "type": "object",
@ -4794,7 +4866,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"VagrantConfig": { "VagrantConfig": {
"type": "object", "type": "object",
@ -4842,7 +4915,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"VcshConfig": { "VcshConfig": {
"type": "object", "type": "object",
@ -4863,7 +4937,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"VConfig": { "VConfig": {
"type": "object", "type": "object",
@ -4915,7 +4990,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"ZigConfig": { "ZigConfig": {
"type": "object", "type": "object",
@ -4963,7 +5039,8 @@
"type": "string" "type": "string"
} }
} }
} },
"additionalProperties": false
}, },
"CustomConfig": { "CustomConfig": {
"type": "object", "type": "object",
@ -5045,7 +5122,8 @@
"default": false, "default": false,
"type": "boolean" "type": "boolean"
} }
} },
"additionalProperties": false
}, },
"Either_for_Boolean_and_String": { "Either_for_Boolean_and_String": {
"anyOf": [ "anyOf": [

View File

@ -1,7 +1,7 @@
[character] [character]
success_symbol = "[>](bold green)" success_symbol = "[>](bold green)"
error_symbol = "[x](bold red)" error_symbol = "[x](bold red)"
vicmd_symbol = "[<](bold green)" vimcmd_symbol = "[<](bold green)"
[git_commit] [git_commit]
tag_symbol = " tag " tag_symbol = " tag "

View File

@ -16,7 +16,7 @@ style = "blue"
[character] [character]
success_symbol = "[](purple)" success_symbol = "[](purple)"
error_symbol = "[](red)" error_symbol = "[](red)"
vicmd_symbol = "[](green)" vimcmd_symbol = "[](green)"
[git_branch] [git_branch]
format = "[$branch]($style)" format = "[$branch]($style)"

View File

@ -642,8 +642,8 @@ are only supported in fish due to [upstream issues with mode detection in zsh](h
### Variables ### Variables
| Variable | Example | Description | | Variable | Example | Description |
| -------- | ------- | --------------------------------------------------------------------- | | -------- | ------- | -------------------------------------------------------------------------------------------------------- |
| symbol | | A mirror of either `success_symbol`, `error_symbol` or `vicmd_symbol` | | symbol | | A mirror of either `success_symbol`, `error_symbol`, `vimcmd_symbol` or `vimcmd_replace_one_symbol` etc. |
### Examples ### Examples

View File

@ -50,7 +50,11 @@ impl<'a, T: Deserialize<'a> + Default> ModuleConfig<'a, ValueError> for T {
} }
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(untagged)] #[serde(untagged)]
pub enum Either<A, B> { pub enum Either<A, B> {
First(A), First(A),

View File

@ -2,7 +2,11 @@ use serde::{Deserialize, Serialize};
use std::collections::HashMap; use std::collections::HashMap;
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
/// ## AWS /// ## AWS
/// ///

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct AzureConfig<'a> { pub struct AzureConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct BatteryConfig<'a> { pub struct BatteryConfig<'a> {
pub full_symbol: &'a str, pub full_symbol: &'a str,
@ -31,7 +35,11 @@ impl<'a> Default for BatteryConfig<'a> {
} }
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct BatteryDisplayConfig<'a> { pub struct BatteryDisplayConfig<'a> {
pub threshold: i64, pub threshold: i64,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct BufConfig<'a> { pub struct BufConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct BunConfig<'a> { pub struct BunConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CConfig<'a> { pub struct CConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CharacterConfig<'a> { pub struct CharacterConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CMakeConfig<'a> { pub struct CMakeConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CmdDurationConfig<'a> { pub struct CmdDurationConfig<'a> {
pub min_time: i64, pub min_time: i64,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CobolConfig<'a> { pub struct CobolConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CondaConfig<'a> { pub struct CondaConfig<'a> {
pub truncation_length: usize, pub truncation_length: usize,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ContainerConfig<'a> { pub struct ContainerConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CrystalConfig<'a> { pub struct CrystalConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -3,7 +3,11 @@ use crate::config::{Either, VecOr};
use serde::{self, Deserialize, Serialize}; use serde::{self, Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct CustomConfig<'a> { pub struct CustomConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct DamlConfig<'a> { pub struct DamlConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct DartConfig<'a> { pub struct DartConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct DenoConfig<'a> { pub struct DenoConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -3,7 +3,11 @@ use indexmap::IndexMap;
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct DirectoryConfig<'a> { pub struct DirectoryConfig<'a> {
pub truncation_length: i64, pub truncation_length: i64,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct DockerContextConfig<'a> { pub struct DockerContextConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct DotnetConfig<'a> { pub struct DotnetConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ElixirConfig<'a> { pub struct ElixirConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ElmConfig<'a> { pub struct ElmConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct EnvVarConfig<'a> { pub struct EnvVarConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ErlangConfig<'a> { pub struct ErlangConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct FillConfig<'a> { pub struct FillConfig<'a> {
pub style: &'a str, pub style: &'a str,

View File

@ -2,7 +2,11 @@ use serde::{Deserialize, Serialize};
use std::collections::HashMap; use std::collections::HashMap;
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GcloudConfig<'a> { pub struct GcloudConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GitBranchConfig<'a> { pub struct GitBranchConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GitCommitConfig<'a> { pub struct GitCommitConfig<'a> {
pub commit_hash_length: usize, pub commit_hash_length: usize,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GitMetricsConfig<'a> { pub struct GitMetricsConfig<'a> {
pub added_style: &'a str, pub added_style: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GitStateConfig<'a> { pub struct GitStateConfig<'a> {
pub rebase: &'a str, pub rebase: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GitStatusConfig<'a> { pub struct GitStatusConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct GoConfig<'a> { pub struct GoConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct HaskellConfig<'a> { pub struct HaskellConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct HelmConfig<'a> { pub struct HelmConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct HgBranchConfig<'a> { pub struct HgBranchConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct HostnameConfig<'a> { pub struct HostnameConfig<'a> {
pub ssh_only: bool, pub ssh_only: bool,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct JavaConfig<'a> { pub struct JavaConfig<'a> {
pub disabled: bool, pub disabled: bool,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct JobsConfig<'a> { pub struct JobsConfig<'a> {
pub threshold: i64, pub threshold: i64,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct JuliaConfig<'a> { pub struct JuliaConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct KotlinConfig<'a> { pub struct KotlinConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -2,7 +2,11 @@ use serde::{Deserialize, Serialize};
use std::collections::HashMap; use std::collections::HashMap;
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct KubernetesConfig<'a> { pub struct KubernetesConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize, Default)] #[derive(Clone, Deserialize, Serialize, Default)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct LineBreakConfig { pub struct LineBreakConfig {
pub disabled: bool, pub disabled: bool,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct LocalipConfig<'a> { pub struct LocalipConfig<'a> {
pub ssh_only: bool, pub ssh_only: bool,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct LuaConfig<'a> { pub struct LuaConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct MemoryConfig<'a> { pub struct MemoryConfig<'a> {
pub threshold: i64, pub threshold: i64,

View File

@ -82,7 +82,11 @@ pub mod zig;
pub use starship_root::*; pub use starship_root::*;
#[derive(Serialize, Deserialize, Clone, Default)] #[derive(Serialize, Deserialize, Clone, Default)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct FullConfig<'a> { pub struct FullConfig<'a> {
// Meta // Meta

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct NimConfig<'a> { pub struct NimConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct NixShellConfig<'a> { pub struct NixShellConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct NodejsConfig<'a> { pub struct NodejsConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct OCamlConfig<'a> { pub struct OCamlConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct OspConfig<'a> { pub struct OspConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct PackageConfig<'a> { pub struct PackageConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct PerlConfig<'a> { pub struct PerlConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct PhpConfig<'a> { pub struct PhpConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct PulumiConfig<'a> { pub struct PulumiConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct PureScriptConfig<'a> { pub struct PureScriptConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -3,7 +3,11 @@ use crate::config::VecOr;
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct PythonConfig<'a> { pub struct PythonConfig<'a> {
pub pyenv_version_name: bool, pub pyenv_version_name: bool,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct RakuConfig<'a> { pub struct RakuConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct RedConfig<'a> { pub struct RedConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct RLangConfig<'a> { pub struct RLangConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct RubyConfig<'a> { pub struct RubyConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct RustConfig<'a> { pub struct RustConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ScalaConfig<'a> { pub struct ScalaConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ShellConfig<'a> { pub struct ShellConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ShLvlConfig<'a> { pub struct ShLvlConfig<'a> {
pub threshold: i64, pub threshold: i64,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct SingularityConfig<'a> { pub struct SingularityConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct SpackConfig<'a> { pub struct SpackConfig<'a> {
pub truncation_length: usize, pub truncation_length: usize,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Serialize, Deserialize, Debug)] #[derive(Clone, Serialize, Deserialize, Debug)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct StarshipRootConfig { pub struct StarshipRootConfig {
#[serde(rename = "$schema")] #[serde(rename = "$schema")]

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct StatusConfig<'a> { pub struct StatusConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct SudoConfig<'a> { pub struct SudoConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct SwiftConfig<'a> { pub struct SwiftConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct TerraformConfig<'a> { pub struct TerraformConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct TimeConfig<'a> { pub struct TimeConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct UsernameConfig<'a> { pub struct UsernameConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct VConfig<'a> { pub struct VConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct VagrantConfig<'a> { pub struct VagrantConfig<'a> {
pub format: &'a str, pub format: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct VcshConfig<'a> { pub struct VcshConfig<'a> {
pub symbol: &'a str, pub symbol: &'a str,

View File

@ -1,7 +1,11 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
#[derive(Clone, Deserialize, Serialize)] #[derive(Clone, Deserialize, Serialize)]
#[cfg_attr(feature = "config-schema", derive(schemars::JsonSchema))] #[cfg_attr(
feature = "config-schema",
derive(schemars::JsonSchema),
schemars(deny_unknown_fields)
)]
#[serde(default)] #[serde(default)]
pub struct ZigConfig<'a> { pub struct ZigConfig<'a> {
pub format: &'a str, pub format: &'a str,