Crates.io | command-group |
lib.rs | command-group |
version | 5.0.1 |
source | src |
created_at | 2021-07-20 08:39:50.790222 |
updated_at | 2023-11-18 08:46:38.642104 |
description | Extension to Command to spawn in a process group |
homepage | https://github.com/watchexec/command-group |
repository | https://github.com/watchexec/command-group |
max_upload_size | |
id | 425042 |
size | 282,734 |
Extension to Command
to spawn in a process group.
[dependencies]
command-group = "5.0.1"
use std::process::Command;
use command_group::CommandGroup;
let mut child = Command::new("watch").arg("ls").group_spawn()?;
let status = child.wait()?;
dbg!(status);
[dependencies]
command-group = { version = "5.0.1", features = ["with-tokio"] }
tokio = { version = "1.10.0", features = ["full"] }
use tokio::process::Command;
use command_group::AsyncCommandGroup;
let mut child = Command::new("watch").arg("ls").group_spawn()?;
let status = child.wait().await?;
dbg!(status);
Also see the Examples!