Crate gethostname

source ·
Expand description

gethostname() for all platforms.

use gethostname::gethostname;

println!("Hostname: {:?}", gethostname());

Functions

  • Get the standard host name for the current machine.