1
1
mirror of https://github.com/Nukesor/pueue.git synced 2024-10-04 03:37:33 +03:00

Merge pull request #568 from 0323pin/main

Add NetBSD support
This commit is contained in:
Arne Christian Beer 2024-09-20 17:35:19 +02:00 committed by GitHub
commit 98ae0d2970
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 313 additions and 299 deletions

View File

@ -48,6 +48,7 @@ TLDR: The new task state representation is more verbose but significantly cleane
### Add
- Add support for NetBSD.
- Add `--all` and `--group` to `pueue log`. [#509](https://github.com/Nukesor/pueue/issues/509)
- Add `--all` and `--group` to `pueue enqueue`. [#558](https://github.com/Nukesor/pueue/issues/558)
- Add `--all` and `--group` to `pueue stash`. [#558](https://github.com/Nukesor/pueue/issues/558)

594
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -64,7 +64,7 @@ crossterm = { version = "0.27", default-features = false }
crossterm = { version = "0.27", default-features = false, features = ["windows"] }
# Test specific dev-dependencies
[target.'cfg(any(target_os = "linux", target_os = "freebsd"))'.dependencies]
[target.'cfg(any(target_os = "linux", target_os = "freebsd", target_os = "netbsd"))'.dependencies]
whoami = "1"
# Test specific Linux dev-dependencies

View File

@ -22,6 +22,7 @@ use command_group::Signal;
#[cfg_attr(target_vendor = "apple", path = "apple.rs")]
#[cfg_attr(target_os = "windows", path = "windows.rs")]
#[cfg_attr(target_os = "freebsd", path = "freebsd.rs")]
#[cfg_attr(target_os = "netbsd", path = "netbsd.rs")]
mod platform;
pub use self::platform::*;

View File

@ -0,0 +1,14 @@
use std::path::Path;
/// Check, whether a specific process is exists or not
pub fn process_exists(pid: u32) -> bool {
return Path::new(&format!("/proc/{}", pid)).is_dir();
}
#[cfg(test)]
pub mod tests {
/// Get all processes in a process group
pub fn get_process_group_pids(pgrp: i32) -> Vec<i32> {
return {};
}
}