euv_cli/command/struct.rs
1use super::*;
2
3/// Installed toolchain status for a single Rust cross-compilation target.
4#[derive(Clone, Debug, Deserialize, Eq, Getter, New, PartialEq, Serialize)]
5pub struct TargetReadiness {
6 /// Target platform label.
7 pub(crate) name: String,
8 /// Rust compiler target triple.
9 pub(crate) triple: String,
10 /// Whether `rustup target list --installed` includes `triple`.
11 #[get(type(copy))]
12 pub(crate) installed: bool,
13}
14
15/// Complete environment readiness report produced by `euv doctor`.
16#[derive(Clone, Data, Debug, Deserialize, Eq, New, PartialEq, Serialize)]
17pub struct DoctorReport {
18 /// Host `rustc --version` output.
19 pub(crate) rustc_version: String,
20 /// Host `cargo --version` output.
21 pub(crate) cargo_version: String,
22 /// Installed `wasm-pack --version` output, or `"missing"`.
23 pub(crate) wasm_pack_version: String,
24 /// Detected Apple SDK path via `xcrun`, or `"missing"`.
25 pub(crate) apple_sdk_path: String,
26 /// Detected `ANDROID_NDK_HOME` path, or `"missing"`.
27 pub(crate) android_ndk_home: String,
28 /// Detected HarmonyOS / OpenHarmony SDK path, or `"missing"`.
29 #[new(skip)]
30 pub(crate) harmony_sdk_path: String,
31 /// Installed `node --version` output for MiniApp / QuickApp / Web tooling, or `"missing"`.
32 #[new(skip)]
33 pub(crate) node_version: String,
34 /// Readiness status across all supported euv platforms.
35 pub(crate) targets: Vec<TargetReadiness>,
36}
37
38/// Result summary emitted after scaffolding a new euv project via `euv new`.
39#[derive(Clone, Debug, Deserialize, Eq, Getter, New, PartialEq, Serialize)]
40pub struct ScaffoldReport {
41 /// Absolute or relative root path of the created project.
42 pub(crate) project_dir: String,
43 /// List of generated files.
44 pub(crate) files: Vec<String>,
45}