Debian Codegraph @

examples/info.rs

raw symbols SCIP
1 #[cfg(all(unix, not(target_os = "macos")))]
2 fn main() {
3 #[cfg(feature = "env_logger")]
4 env_logger::init();
5 match notify_rust::get_server_information() {
6 Ok(info) => {
7 println!("{}:", info.name);
8 println!(" ServerInformation:");
9 println!(" name: {}", info.name);
10 println!(" vendor: {}", info.vendor);
11 println!(" version: {}", info.version);
12 println!(" spec_version: {}", info.spec_version);
13 println!(
14 " capabilities: {:#?}",
15 notify_rust::get_capabilities().unwrap_or_default()
16 );
17 }
18 Err(err) => eprintln!("error: {}", err),
19 }
20 }
21
22 #[cfg(any(target_os = "windows", target_os = "macos"))]
23 fn main() {
24 println!("this is a xdg only feature")
25 }