Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/rust-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,6 @@ jobs:
uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2

- name: Check build
run: cargo check --all-features
# NB: the `gui` feature pulls eframe/egui which raise MSRV above 1.85.
# Verify the default + non-GUI optional features compile on MSRV.
run: cargo check --features signing,http
5 changes: 4 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ chrono = "0.4"
filetime = "0.2"
encoding_rs = "0.8"
crossterm = "0.29"
eframe = "0.34"
eframe = { version = "0.34", optional = true }
rayon = "1.12"
blake3 = { version = "1.8", features = ["mmap"] }
sha2 = "0.11"
Expand All @@ -39,6 +39,9 @@ ureq = { version = "3.3", optional = true }
default = []
signing = ["ed25519-dalek"]
http = ["ureq"]
# Native GUI viewer (eframe/egui). Opt-in because eframe raises MSRV above the
# 1.85.0 baseline; default builds remain pure-CLI and MSRV-clean.
gui = ["eframe"]

[dev-dependencies]
tempfile = "3.27"
Expand Down
4 changes: 3 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,8 @@ enum Commands {
headless: bool,
},

/// GUI review of a saved report
/// GUI review of a saved report (requires `--features gui` at build time)
#[cfg(feature = "gui")]
Gui {
/// Assault report JSON file
#[arg(value_name = "REPORT")]
Expand Down Expand Up @@ -1700,6 +1701,7 @@ fn run_main() -> Result<()> {
}
}

#[cfg(feature = "gui")]
Commands::Gui { report, headless } => {
let content = read_report_bounded(&report)?;
let assault_report: AssaultReport = serde_json::from_str(&content)?;
Expand Down
2 changes: 2 additions & 0 deletions src/report/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
pub mod diff;
pub mod formatter;
pub mod generator;
#[cfg(feature = "gui")]
pub mod gui;
pub mod migration;
pub mod output;
Expand All @@ -19,6 +20,7 @@ use std::path::Path;
pub use diff::{format_diff, load_report};
pub use formatter::{ReportFormatter, ReportView};
pub use generator::ReportGenerator;
#[cfg(feature = "gui")]
pub use gui::ReportGui;
pub use output::ReportOutputFormat;
pub use tui::ReportTui;
Expand Down
Loading