Skip to main content

Crate flashkraft_core

Crate flashkraft_core 

Source
Expand description

FlashKraft Core

This crate contains all shared, framework-free logic that is reused by both the Iced desktop GUI (flashkraft-gui) and the Ratatui TUI (flashkraft-tui).

§Contents

ModuleWhat lives here
domainDomain models — DriveInfo, ImageInfo, drive constraints
flash_helperIn-process flash pipeline — [run_pipeline], FlashEvent, FlashStage
commandsAsync helpers — drive detection
utilsDebug-logging macros (debug_log!, flash_debug!, …)

§Dependency policy

This crate intentionally has no GUI or TUI dependencies (no iced, no ratatui, no crossterm). It may only depend on:

  • OS / system crates (sysinfo, nix, sha2, …)
  • Async utilities (tokio, futures, futures-timer)
  • Persistence (sled, dirs)

Re-exports§

pub use domain::DriveInfo;
pub use domain::ImageInfo;
pub use utils::fmt_bytes;
pub use flash_helper::verify_overall_progress;
pub use flash_helper::FlashEvent;
pub use flash_helper::FlashStage;

Modules§

commands
Commands Module — Core Async Side Effects
domain
Domain Module
flash_helper
Flash Pipeline
utils
Utility modules for FlashKraft Core

Macros§

debug_if
Conditional debug logging - only logs if condition is true
debug_log
Debug logging macro for general application messages
flash_debug
Debug logging macro for flash subscription messages
status_log
Debug logging macro for status messages