(path: String)
| 158 | |
| 159 | #[tauri::command] |
| 160 | fn workspace_verify(path: String) -> VerifyResult { |
| 161 | trace!("workspace_verify: <- {}", path); |
| 162 | let result = if let Err(msg) = workspace::path_available(&path) { |
| 163 | VerifyResult::Err { message: msg } |
| 164 | } else if workspace::exists(&path) { |
| 165 | VerifyResult::Warn { |
| 166 | message: "此工作文件夹下已有配置。若继续则原有配置会被覆盖。", |
| 167 | } |
| 168 | } else { |
| 169 | VerifyResult::Ok { value: () } |
| 170 | }; |
| 171 | trace!("workspace_verify: -> {:?}", result); |
| 172 | result |
| 173 | } |
| 174 | |
| 175 | #[derive(Serialize, Debug)] |
| 176 | #[serde(rename_all = "camelCase")] |
nothing calls this directly
no test coverage detected