pub fn save_wallet(
path: &str,
keypair_bytes: &[u8],
force: bool,
) -> Result<PathBuf, String>Expand description
Save raw keypair bytes to a file in Solana CLI JSON byte-array format.
The file is written with 0o600 permissions (owner read/write only).
Refuses to overwrite an existing file unless force is true.
ยงErrors
Returns a human-readable error string if the file cannot be written or
already exists without force.