Skip to main content

write_env_override_entry

Function write_env_override_entry 

Source
pub async fn write_env_override_entry(
    path: &Path,
    key: &str,
    value: Option<&str>,
) -> Result<()>
Expand description

Set (Some) or remove (None) one key in a shine.env.toml-shaped override file, preserving comments/formatting of unrelated entries and the description of a { value, description } entry being updated. Creates the file (and its parent directory) if it doesn’t exist yet.