From 272e33eb7312868d3734f32eca4c9d16556e2395 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20NEDJAR?= Date: Tue, 28 Apr 2026 12:23:19 +0200 Subject: [PATCH 1/2] chore: cargo fmt --all MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Mechanical reformat. The recent wireless-stack PR introduced a few spots that didn't match rustfmt defaults — running `cargo fmt --all` makes the lint job (informational) fmt check stop reporting diffs. No behavior change. Once this lands, the `continue-on-error: true` on the fmt step in CI can be flipped to false in a follow-up. --- src/open_ocd_task.rs | 9 +-------- src/ui/tab_wireless_stack.rs | 12 +++--------- 2 files changed, 4 insertions(+), 17 deletions(-) diff --git a/src/open_ocd_task.rs b/src/open_ocd_task.rs index e75a4fe..d0653a1 100644 --- a/src/open_ocd_task.rs +++ b/src/open_ocd_task.rs @@ -123,14 +123,7 @@ where .into_string() .map_err(|_| "Failed to convert tmp_dir to string.")?; - cmd.args(&[ - "-s", - &config_folder, - "-s", - &tmp_folder, - "-s", - &ws_foler, - ]); + cmd.args(&["-s", &config_folder, "-s", &tmp_folder, "-s", &ws_foler]); // The xpack-bundled OpenOCD ships its standard scripts alongside the // executable in `/scripts/`. Our .cfg files reference these via diff --git a/src/ui/tab_wireless_stack.rs b/src/ui/tab_wireless_stack.rs index 336da03..42bccf6 100644 --- a/src/ui/tab_wireless_stack.rs +++ b/src/ui/tab_wireless_stack.rs @@ -243,9 +243,7 @@ impl TabWirelessStack { None => { Self::send_log( &mut o, - LogType::Error( - "Flash failed: OpenOCD terminated by signal".into(), - ), + LogType::Error("Flash failed: OpenOCD terminated by signal".into()), ) .await; Self::send_step(&mut o, FwStep::Ready).await; @@ -365,9 +363,7 @@ impl TabWirelessStack { None => { Self::send_log( &mut o, - LogType::Error( - "Flash failed: OpenOCD terminated by signal".into(), - ), + LogType::Error("Flash failed: OpenOCD terminated by signal".into()), ) .await; Self::send_step(&mut o, FwStep::Ready).await; @@ -472,9 +468,7 @@ impl TabWirelessStack { None => { Self::send_log( &mut o, - LogType::Error( - "Flash failed: OpenOCD terminated by signal".into(), - ), + LogType::Error("Flash failed: OpenOCD terminated by signal".into()), ) .await; Self::send_step(&mut o, FwStep::Ready).await; From de882e20e39a1c8079d95710baa982e862b14c5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20NEDJAR?= Date: Tue, 28 Apr 2026 12:38:48 +0200 Subject: [PATCH 2/2] chore: rename ws_foler -> ws_folder + fix its error message Local variable typo and a copy-pasted map_err that said "config path" for the wireless stack folder. Per Copilot review on PR #13. --- src/open_ocd_task.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/open_ocd_task.rs b/src/open_ocd_task.rs index d0653a1..ec7a51a 100644 --- a/src/open_ocd_task.rs +++ b/src/open_ocd_task.rs @@ -113,17 +113,17 @@ where .into_string() .map_err(|_| "Failed to convert config path to string")?; - let ws_foler = dirs::get_wireless_stack_dir()? + let ws_folder = dirs::get_wireless_stack_dir()? .into_os_string() .into_string() - .map_err(|_| "Failed to convert config path to string")?; + .map_err(|_| "Failed to convert wireless stack path to string")?; let tmp_folder = dirs::get_tmp_dir()? .into_os_string() .into_string() .map_err(|_| "Failed to convert tmp_dir to string.")?; - cmd.args(&["-s", &config_folder, "-s", &tmp_folder, "-s", &ws_foler]); + cmd.args(&["-s", &config_folder, "-s", &tmp_folder, "-s", &ws_folder]); // The xpack-bundled OpenOCD ships its standard scripts alongside the // executable in `/scripts/`. Our .cfg files reference these via