(
commands: Vec<String>,
)
| 250 | |
| 251 | #[tauri::command] |
| 252 | pub async fn check_commands_exist( |
| 253 | commands: Vec<String>, |
| 254 | ) -> Result<Vec<(String, CheckCommandResponse)>, String> { |
| 255 | let cmd_refs: Vec<&str> = commands.iter().map(|s| s.as_str()).collect(); |
| 256 | let results = system::check_commands(&cmd_refs); |
| 257 | |
| 258 | Ok(results |
| 259 | .into_iter() |
| 260 | .map(|(name, result)| { |
| 261 | ( |
| 262 | name, |
| 263 | CheckCommandResponse { |
| 264 | exists: result.exists, |
| 265 | path: result.path, |
| 266 | }, |
| 267 | ) |
| 268 | }) |
| 269 | .collect()) |
| 270 | } |
| 271 | |
| 272 | #[tauri::command] |
| 273 | pub async fn run_system_command( |
nothing calls this directly
no test coverage detected