-
-
Save dEajL3kA/6e4981a40223ed567f8ee5b298d48119 to your computer and use it in GitHub Desktop.
Debug outputs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// DEBUG DOCS_RS | |
if let Ok(list) = fs::read_dir("/usr/lib/x86_64-linux-gnu") { | |
eprintln!("[/usr/lib/x86_64-linux-gnu]"); | |
for entry in list { | |
if let Ok(file) = entry { | |
let name = file.file_name().into_string().unwrap_or_default(); | |
if name.to_ascii_lowercase().contains("tss") { | |
eprintln!("{}", name); | |
} | |
} | |
} | |
eprintln!(); | |
} | |
if let Ok(list) = fs::read_dir("/usr/lib/x86_64-linux-gnu/pkgconfig") { | |
eprintln!("[/usr/lib/x86_64-linux-gnu/pkgconfig]"); | |
for entry in list { | |
if let Ok(file) = entry { | |
let name = file.file_name().into_string().unwrap_or_default(); | |
if name.to_ascii_lowercase().contains("tss") { | |
eprintln!("{}", name); | |
} | |
} | |
} | |
eprintln!(); | |
} | |
if let Ok(output) = std::process::Command::new("pkg-config").arg("--list-all").output() { | |
eprintln!("[pkg-config]"); | |
for line in str::from_utf8(&output.stdout).unwrap_or_default().split('\n') { | |
if line.to_ascii_lowercase().contains("tss") { | |
eprintln!("{}", line); | |
} | |
} | |
for line in str::from_utf8(&output.stderr).unwrap_or_default().split('\n') { | |
if line.to_ascii_lowercase().contains("tss") { | |
eprintln!("{}", line); | |
} | |
} | |
eprintln!(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment