pub fn save(path: &Path, file: &ConfigFile) -> SshCliResult<()>Expand description
Saves the configuration file atomically with flock and 0o600.
Takes the lock for the write only. Callers that read, mutate and write back must
use lock_config instead, or they race with a concurrent invocation.
ยงErrors
Returns an error if serialization, atomic write, or permission hardening fails.