rigtop_core/lib.rs
1//! Data collection core shared by the rigtop TUI and GUI.
2//!
3//! - [`snapshot`]: the serializable measurement types exchanged between data
4//! sources and front-ends (also the wire format for remote monitoring).
5//! - [`source`]: the [`DataSource`] trait and the [`LocalSource`] implementation.
6//! - [`config`]: user configuration (sensor labels, SMART directory).
7//! - [`system`], [`gpu`], [`smart`], `linux`: the individual collectors;
8//! [`fill`]: when filesystems will be full; [`nut`]: UPSes, from Network
9//! UPS Tools.
10//! - [`agent`], [`remote`]: remote monitoring over SSH (`rigtop --agent` and
11//! the [`remote::RemoteSource`] that talks to it).
12//! - [`demo`]: made-up hosts for trying the interface (`--demo`).
13//! - [`snooze`]: alerts silenced for a while, shared by the front-ends.
14//! - [`worker`], [`view`], [`format`]: front-end helpers shared by the TUI
15//! and the GUI (background polling thread, process table logic, units).
16
17pub mod agent;
18pub mod config;
19pub mod demo;
20pub mod fill;
21pub mod format;
22pub mod gpu;
23pub mod hosts;
24// Parsed (and tested) everywhere, used on Windows.
25#[cfg(any(windows, test))]
26mod lhm;
27#[cfg(target_os = "linux")]
28pub mod linux;
29pub mod nut;
30pub mod package;
31pub mod public_ip;
32pub mod remote;
33pub mod smart;
34pub mod snapshot;
35pub mod snooze;
36pub mod source;
37pub mod system;
38pub mod update;
39pub mod view;
40pub mod widget;
41#[cfg(windows)]
42mod windows;
43pub mod worker;
44
45pub use config::Config;
46pub use snapshot::Snapshot;
47pub use source::{DataSource, LocalSource, MIN_POLL_INTERVAL, ProcessSignal, SourceError};