Registry / utility / platform-info

platform-info

JSON →
library2.1.0rscratesunverified

A simple cross-platform interface to get info about a system, such as OS version and hostname.

# Cargo.toml [dependencies] platform-info = "2.1.0"
INSTALL
IMPORT
SIG · PLATFORM-INFO
P
platform-info
utilityrustv2.1.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

PlatformInfo
use platform_info::PlatformInfo;

Retrieves and prints system information like OS type and hostname.

use platform_info::*; fn main() { let info = PlatformInfo::new().unwrap(); println!("OS: {}", info.os_type()); println!("Hostname: {}", info.hostname()); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
2.1.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
platform-info — cargo add platform-info · libregistry