Important
I'm looking for someone to maintain this project in the Fedora COPR repositories.
If you're interested in maintaining it, please don't hesitate to reach out.
Note
This project is under active development.
As I continue learning Zig, updates may take some time — your contributions, feedback, and patience are greatly appreciated!
High-performance Waybar modules written in Zig for efficient system monitoring
zig-waybar-contrib is a collection of lightweight, blazingly fast Waybar modules built with Zig. These modules are designed to provide accurate system monitoring with minimal resource usage, taking advantage of Zig's performance characteristics and memory safety.
Key Features:
- 🚀 High Performance: Native binaries with minimal overhead.
- 🛡️ Memory Safe: Built with Zig's safety features.
- 🧩 Drop-in Replacement: Compatible with Waybar's custom module interface.
- 🤖 Auto-Detection: Automatically detects system capabilities (GPU, Package Managers).
| Module | Description |
|---|---|
| Updates | Tracks system package updates |
| GPU | Monitors GPU stats |
| Memory | Reports RAM usage and statistics |
| Ping | Measures network latency |
| CPU | Displays per-core CPU usage |
See MODULES for detailed documentation on each module.
You can easily install the latest version from the AUR.
# Using paru
paru -S zig-waybar-contrib
# Using yay
yay -S zig-waybar-contribNote
This script doesn't need root permissions.
The installation script automates cloning, building, and installing.
bash -c "$(curl -fsSL https://raw.githubusercontent.com/erffy/zig-waybar-contrib/0.16-dev/install.sh)"This script installs into your $HOME directory ($HOME/.zig-waybar-contrib) and places its binaries in $HOME/.local/bin.
To build from source, you need Zig installed (check build.zig for version requirements).
git clone https://github.com/erffy/zig-waybar-contrib.git
cd zig-waybar-contrib
zig build -Doptimize=ReleaseFastTip
The build system automatically detects available libraries (like rocm-smi, nvidia-ml) and package managers. If dependencies for gpu or updates modules are missing, those modules might be skipped.
Binaries will be available in zig-out/bin/.
Add the modules to your Waybar configuration. You can include the provided config file or define modules manually.
Method 1: Include Config
Method 2: Manual Definition
See config.waybar.jsonc for the default configuration values.
See CONTRIBUTING
- Zig Team - For creating an amazing systems programming language
- Waybar Contributors - For the excellent status bar that makes this possible
- Community - For feedback, bug reports, and contributions
Made with ❤️ by Me
Star ⭐ this repo if you find it useful!
This project is licensed under the GNU General Public License v3.0. See LICENSE for details.
{ // Load module configurations from zig-waybar-contrib "include": [ "/etc/zig-waybar-contrib/config.jsonc" // Or path to your local config ], "modules-right": [ "custom/updates", "custom/gpu", "custom/memory", "custom/ping", "custom/cpu" ] }