Vendor dependencies
Let's see how I like this workflow.
This commit is contained in:
parent
34d1830413
commit
9c435dc440
7500 changed files with 1665121 additions and 99 deletions
17
vendor/open/src/haiku.rs
vendored
Normal file
17
vendor/open/src/haiku.rs
vendored
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
use std::{ffi::OsStr, io, process::Command};
|
||||
|
||||
use crate::{CommandExt, IntoResult};
|
||||
|
||||
pub fn that<T: AsRef<OsStr>>(path: T) -> io::Result<()> {
|
||||
Command::new("/bin/open")
|
||||
.arg(path.as_ref())
|
||||
.status_without_output()
|
||||
.into_result()
|
||||
}
|
||||
|
||||
pub fn with<T: AsRef<OsStr>>(path: T, app: impl Into<String>) -> io::Result<()> {
|
||||
Command::new(app.into())
|
||||
.arg(path.as_ref())
|
||||
.status_without_output()
|
||||
.into_result()
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue