[][src]Function hostname::get

pub fn get() -> Result<OsString>

Return the system hostname.

Example

let name = hostname::get()?;

Errors

If this function encounters any form of error, an error variant will be returned; in practice it is rare to be happen.