Skip to main content

parse_manifest_str

Function parse_manifest_str 

Source
pub fn parse_manifest_str(
    text: &str,
    fallback_name: &str,
) -> Result<PluginManifest>
Expand description

Parse text (a plugin.toml’s contents) into a PluginManifest, using fallback_name (the plugin’s directory name) when the manifest itself doesn’t declare name. A malformed TOML document is a clean Err, never a panic; a malformed INDIVIDUAL [[tools]]/[[hooks]] entry (empty name/command/event) is silently skipped rather than failing the whole manifest (see PluginManifest::tools’s doc comment).