command_stream/execa/
mod.rs1mod command;
17mod options;
18mod process;
19mod result;
20
21pub use command::{Execa, ExecaCommand};
22pub use options::{CancelSignal, Cancellation, Options};
23pub use process::Subprocess;
24pub use result::{ExecaError, ExecaOutcome, ExecaResult};
25use std::ffi::OsString;
26
27pub fn execa<P, I, S>(file: P, args: I) -> ExecaCommand
28where
29 P: Into<OsString>,
30 I: IntoIterator<Item = S>,
31 S: Into<OsString>,
32{
33 Execa::default().command(file, args)
34}
35
36pub fn execa_sync<P, I, S>(file: P, args: I) -> ExecaOutcome
37where
38 P: Into<OsString>,
39 I: IntoIterator<Item = S>,
40 S: Into<OsString>,
41{
42 execa(file, args).sync()
43}
44
45pub fn execa_node<P, I, S>(file: P, args: I) -> ExecaCommand
46where
47 P: Into<OsString>,
48 I: IntoIterator<Item = S>,
49 S: Into<OsString>,
50{
51 Execa::default().node(file, args)
52}
53
54pub fn execa_compat(options: Options) -> Execa {
55 Execa::new(options)
56}