oneshot: simplify API surface

Kill 5 wrapper functions (run_and_apply chain, run_one_agent_excluded),
drop dead llm_tag parameter, clean up scan_pid_files parsing.

Public API: run_one_agent, run_one_agent_with_keys, spawn_agent,
scan_pid_files.

Co-Authored-By: Proof of Concept <poc@bcachefs.org>
This commit is contained in:
ProofOfConcept 2026-04-04 17:33:36 -04:00 committed by Kent Overstreet
parent 0f4ca9e2f2
commit a1fb3fe557
4 changed files with 136 additions and 224 deletions

View file

@ -74,8 +74,8 @@ pub fn consolidate_full_with_progress(
*store = Store::load()?;
}
match oneshot::run_and_apply(store, agent_type, *count, "consolidate") {
Ok(()) => {
match oneshot::run_one_agent(store, agent_type, *count, None, &|_| {}) {
Ok(_) => {
let msg = " Done".to_string();
log_line(&mut log_buf, &msg);
on_progress(&msg);