// Save the provided keypair to the specified path.
Save the provided keypair to the specified path.
Save the provided keypair to the specified path .
fn save_ed25519(
    keypair: &identity::ed25519::Keypair,
    keypair_path: &str,
) -> Result<(), Box<dyn error::Error>> {
    let mut keypair_file = fs::File::create(&keypair_path)?;
    keypair_file.write_all(&keypair.encode())?;
    Ok(())
}
fn save_ed25519 ( keypair : & identity :: ed25519 :: Keypair , keypair_path : & str , ) -> Result < ( ) , Box < dyn error :: Error > > { let mut keypair_file = fs :: File :: create ( & keypair_path ) ? ; keypair_file . write_all ( & keypair . encode ( ) ) ? ; Ok ( ( ) ) }
Save the provided keypair to the specified path.
Save the provided keypair to the specified path .
keypair
&identity::ed25519::Keypair
keypair_path
&str