fix(cli): use obscura-worker.exe on Windows (#140)

This commit is contained in:
h4ckf0r0day authored and GitHub committed 2026-05-13 22:56:09 +02:00
1 parent deb5be90ee
commit 27cd10156b
1 file changed
+3 -2
+3 -2
View File
@@ -544,10 +544,11 @@ async fn run_parallel_scrape(
); );
} }
let worker_name = if cfg!(windows) { "obscura-worker.exe" } else { "obscura-worker" };
let worker_path = std::env::current_exe() let worker_path = std::env::current_exe()
.ok() .ok()
.and_then(|p| p.parent().map(|d| d.join("obscura-worker"))) .and_then(|p| p.parent().map(|d| d.join(worker_name)))
.unwrap_or_else(|| std::path::PathBuf::from("obscura-worker")); .unwrap_or_else(|| std::path::PathBuf::from(worker_name));
if !worker_path.exists() { if !worker_path.exists() {
anyhow::bail!( anyhow::bail!(