Expand description
SSH command generator. Example usage:
use nbssh::{Address, SshParams};
use std::process::Command;
let params = SshParams {
address: Address::from_host("myHost"),
..Default::default()
};
let args = params.command(&["echo", "hello"]);
Command::new(&args[0]).args(&args[1..]).status().unwrap();
Structs§
- Address
- Host and port number. Can be serialized and deserialized with serde using the “host[:port]” format.
- SshParams
- Inputs for an SSH command, excluding the remote command itself.
Enums§
- Address
Error - Address parse errors.
Constants§
- DEFAULT_
SSH_ PORT - Default SSH port number 22.