fix: tryfix directory creation
All checks were successful
CI / Check, test, lint (push) Successful in 30s

This commit is contained in:
2026-05-20 11:41:39 +02:00
parent 6a4c5d41a1
commit e9ab6c6a0f

View File

@@ -32,18 +32,8 @@ pub fn execute(worker_name: Option<&str>, cmd: Vec<String>, no_sync: bool) -> Re
.to_string_lossy()
.to_string();
// ── 1. Sync directory ─────────────────────────────────────────────────────
if no_sync {
eprintln!("Skipping sync (--no-sync).");
} else {
eprintln!("Syncing to {}...", worker.name);
sync::push_dir(&worker, &std::env::current_dir()?, &work_dir)
.context("directory sync failed")?;
}
// ── 1. Create remote directories ─────────────────────────────────────────
// Must happen before sync so rsync has a destination to write into.
// Done first so rsync has an existing destination to write into.
ssh::run_capture(&worker, &format!("mkdir -p {} {}", job_dir, work_dir))
.context("failed to create remote directories")?;