Add documentation for recent functions
This commit is contained in:
@@ -77,10 +77,11 @@ pub fn main() -> Result<()> {
|
||||
let temp = NamedTempFile::with_suffix(".png").context("Unable to create file for image")?;
|
||||
image.save(temp.path()).context("Unable to save image")?;
|
||||
|
||||
let open_program = cfg_select! {
|
||||
unix => "xdg-open",
|
||||
_ => panic!("Unknown system"),
|
||||
};
|
||||
let open_program: &str = cfg_select! {
|
||||
unix => Some("xdg-open"),
|
||||
_ => None,
|
||||
}
|
||||
.expect("No available program to open images");
|
||||
|
||||
Command::new(open_program)
|
||||
.arg(temp.path())
|
||||
|
||||
Reference in New Issue
Block a user