feat(module): Add a meson devenv indicator (#4389)

* feat(module): Add a meson devenv indicator

Adds a Meson Developer Environment indicator, if the MESON_DEVENV
variable is set. Inside a `meson devenv`, the prompt will include the
current Meson project name

This also contains a new Truncate utility function, which may be adapted for other modules in the future

* docs: Add Meson to presets
This commit is contained in:
Jamie
2022-10-11 09:02:46 -07:00
committed by GitHub
parent 4107031331
commit 355800f814
14 changed files with 346 additions and 0 deletions
+47
View File
@@ -864,6 +864,21 @@
}
]
},
"meson": {
"default": {
"disabled": false,
"format": "via [$symbol$project]($style) ",
"style": "blue bold",
"symbol": "⬢ ",
"truncation_length": 4294967295,
"truncation_symbol": "…"
},
"allOf": [
{
"$ref": "#/definitions/MesonConfig"
}
]
},
"nim": {
"default": {
"detect_extensions": [
@@ -3600,6 +3615,38 @@
},
"additionalProperties": false
},
"MesonConfig": {
"type": "object",
"properties": {
"truncation_length": {
"default": 4294967295,
"type": "integer",
"format": "uint32",
"minimum": 0.0
},
"truncation_symbol": {
"default": "…",
"type": "string"
},
"format": {
"default": "via [$symbol$project]($style) ",
"type": "string"
},
"symbol": {
"default": "⬢ ",
"type": "string"
},
"style": {
"default": "blue bold",
"type": "string"
},
"disabled": {
"default": false,
"type": "boolean"
}
},
"additionalProperties": false
},
"NimConfig": {
"type": "object",
"properties": {