Skip to content

Commit 1f1a5ac

Browse files
committed
feat: accept same cli args as squeue
1 parent 7e6678d commit 1f1a5ac

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/job_watcher.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
use std::env;
12
use std::path::PathBuf;
23
use std::{io::BufRead, process::Command, thread, time::Duration};
34

@@ -40,8 +41,11 @@ impl JobWatcher {
4041
.map(|s| s.to_owned() + ":" + output_separator)
4142
.join(",");
4243

44+
let cli_args = env::args().skip(1).collect::<Vec<_>>();
45+
4346
loop {
4447
let jobs: Vec<Job> = Command::new("squeue")
48+
.args(&cli_args)
4549
.arg("-h")
4650
.arg("-O")
4751
.arg(&output_format)

0 commit comments

Comments
 (0)