pub fn read(lock_path: &Path) -> Result<Option<LockFile>>Expand description
Read and JSON-parse <home>/running.lock. Returns:
Ok(None)if the file does not exist (agent stopped).Ok(Some(_))if the file exists and parses successfully.Err(_)if the file exists but I/O fails or JSON is malformed.