Crate open [] [src]

Use this library to open a path or URL using the program configured on the system.

Usage

extern crate open;
 
open::that("/path/to/file/with.fancy-extension");
if open::that("https://google.de").is_ok() {
    println!("Look at your browser !");
}

Notes

As an operating system program is used, chances are that the open operation fails. Therfore, you are advised to at least check the result with .is_err() and behave accordingly, e.g. by letting the user know what you tried to open, and failed.

Functions

that