Skip to main content

euv_cli/fmt/
struct.rs

1use super::*;
2
3/// Structured summary produced by `euv fmt` across workspace text files, Rust sources, and macro invocations.
4#[derive(Clone, Data, Debug, Default, Deserialize, Eq, New, PartialEq, Serialize)]
5pub struct FmtReport {
6    /// Total `.rs` files scanned across the target workspace or directory.
7    #[get(type(copy))]
8    pub(crate) files_scanned: usize,
9    /// Number of `.rs` files whose macro blocks required reformatting.
10    #[get(type(copy))]
11    pub(crate) files_formatted: usize,
12    /// Total `euv` macro blocks (`view!`, `style!`, etc.) normalized.
13    #[get(type(copy))]
14    pub(crate) macros_formatted: usize,
15    /// Total non-Rust text files (`.md`, `.yml`, `.yaml`, `.json`, `.toml`, etc.) scanned via `crate-cli`.
16    #[get(type(copy))]
17    pub(crate) text_files_scanned: usize,
18    /// Number of non-Rust text files normalized via `crate-cli`.
19    #[get(type(copy))]
20    pub(crate) text_files_formatted: usize,
21    /// Whether `--check` dry-run verification mode was active.
22    #[get(type(copy))]
23    pub(crate) check_only: bool,
24    /// Relative or display paths of files needing or receiving formatting.
25    pub(crate) changed_files: Vec<String>,
26}