Warning
WIP, limited functionality.
Backend functional with limitations.
Tui available with limitations (WIP)
No Gui available at the moment.
Prerequisites: .NET SDK 10.0.203 (the exact version is pinned in global.json).
Platform: Linux (primary), Windows (partial, WIP).
git clone https://github.com/Akeoott/ZenMonitor
cd ZenMonitor
dotnet restore
dotnet build
# Run the CLI frontend
# (requires sudo/admin privileges, to bypass add `-n` after `-r cli`)
dotnet run --project ZenMonitor -- -r cliSee CONTRIBUTING.md for the full contribution workflow and our Code of Conduct.
ZenMonitor is a modern task manager built on .NET 10.0 (C# only). It uses a modular, interface-driven backend for system telemetry and a Producer-Consumer pattern to decouple data collection from rendering. Currently Linux-only; GUI frontend is planned but not yet implemented.
A background data loop calls Update() on each hardware service at a configurable interval. Frontends (CLI, TUI, or planned GUI) can then read the latest snapshot and render it to the user.
- Dependency Injection: All hardware services are registered as singletons via
Microsoft.Extensions.DependencyInjection. Frontends (Cli/Tui/Gui) are registered as transient. - Root required: The app checks for root (Linux) or admin (Windows) privileges at startup unless
--no-sudois passed.
All telemetry data flows through interfaces in ZenMonitor.Core/Interfaces/. Each exposes a void Update() method plus typed getters:
| Interface | Provides |
|---|---|
ICpu |
CPU usage, temperature, frequency |
IDrive |
Disk I/O, partition usage |
IGpu |
GPU utilization, VRAM |
IHelper |
Utility / helper methods |
IMemory |
RAM usage, swap |
INetwork |
Network throughput, interfaces |
ISystem |
OS info, uptime, hostname |
Concrete implementations live in ZenMonitor.Core/Services/<Platform>/.
- Implement the interface — create a new class in
Core/Services/<Platform>/that implements the relevantIXxxinterface. - Register in DI — add the service in
Program.cs→InitProgramusing the DI container. - Add a frontend view — consume the data from a
Cli,Tui, orGuiview.
dotnet run --project ZenMonitor -- -r cli # Run CLI mode
dotnet run --project ZenMonitor -- -r cli -l d # Debug logging
dotnet run --project ZenMonitor -- -r cli -d 500 # 500ms update interval
dotnet run --project ZenMonitor -- -r cli -n # Skip root check
dotnet run --project ZenMonitor -- -r cli -n -f # Force launch no matter whatOptions:
-r|--run <cli|tui|gui>— required, selects frontend mode-d|--delay <ms>— update interval, 100–10000ms, default 1000-n|--no-sudo <bool>— bypass privilege check-f|--force-run <bool>— run regardless of unsupported OS (may break)-c|--cli-log <bool>— enable console log output (cli mode only)-l|--log-level <level>—t|trace,d|debug,i|info,w|warning,e|error,c|critical
Logs are written to logs/ZenMonitor.log (cleared on each run).
The project uses xUnit with platform-filtered test categories that match the CI workflow (.github/workflows/tests.yml).
# Run all tests
dotnet test
# Platform-specific runs
dotnet test --filter "Platform=Linux"
dotnet test --filter "Platform=Windows"
# With code coverage (local)
dotnet test --collect:"XPlat Code Coverage" --settings coverlet.runsettings- Coverage configuration is in
coverlet.runsettingsat the repo root. - Linux service tests use
System.IO.Abstractions.MockFileSystemto parse/procand/sysfiles without real hardware. - Test data fixtures live in
ZenMonitor.Tests/Services/Linux/TestData/.
- ZenMonitor/
./Program.cs: Entry point.
ContainsInitProgram(Spectre.Console.CliAsyncCommand<ProgramSettings>), DI wiring, logging setup via Serilog, privilege check (Linux root / Windows admin), and mode dispatch (cli/tui/gui)../ProgramSettings.cs: CLI argument definitions with Spectre.Console validation../ProgramHelper.cs: Shared helpers (logging setup, service provider building, runtime safety checks).
- ZenMonitor.Core/
./Interfaces/: Hardware abstraction interfaces. Each has avoid Update()method plus typed getters../Models/: Immutable C#recordtypes used as data snapshots../Services/Linux/: Concrete Linux implementations of all interfaces../Services/Windows/: Concrete future Windows implementations of all interfaces.
- ZenMonitor.Cli/
./Monitor.cs: CLI frontend. Injects all hardware interfaces, runs a background data loop and prints raw telemetry values to stdout.
- ZenMonitor.Tui/
./Monitor.cs: TUI frontend using Terminal.Gui. Injects all hardware interfaces, runs a background data loop, and updates views viaapp.Invoke(window.RefreshData)../Views/: TUI view components:HeaderView— system info headerCpuSection,GpuSection,MemoryDiskSection,NetworkSection— per-component panelsPlaceholderSection— reserved slotSectionVisibility— toggle-state model for key-based section switching (1–5)Window— main window with dynamic grid layout, section visibility toggling, andRefreshDatadispatch
- ZenMonitor.Gui/
./: Planned GUI frontend (not implemented).
- ZenMonitor.Tests/
./Services/Linux/: xUnit test suite.
UsesSystem.IO.Abstractions.MockFileSystemto test Linux service parsing logic without real hardware.
- Stack: C# 100%, .NET 10.0.203
- Key dependencies:
Spectre.Console.Cli(CLI parsing),Serilog(logging),Microsoft.Extensions.DependencyInjection,System.IO.Abstractions(testability) - Test framework: xUnit +
coverlet(coverage config incoverlet.runsettings) - Platform: Linux only (Windows support planned)
- License: LGPL-3.0
Note
Documentation if you need more help: DeepWiki/Akeoott/ZenMonitor
I wanna mention that it provides a broad overview.
YOU CAN NOT 100% rely on it. You know how AI is, its not a permanent solution. Just a temporary fix.