Skip to main content

open_command_for

Function open_command_for 

Source
pub fn open_command_for(os: &str, url: &str) -> (String, Vec<String>)
Expand description

The launcher command and arguments for url on os.

os is the value of std::env::consts::OS. An unrecognized OS falls back to xdg-open, the freedesktop standard, which covers the BSDs and other Unixes.

On Windows the empty "" title argument to start matters: start treats a single quoted argument as a window title, so a URL would be swallowed without a placeholder title ahead of it.