Skip to content

⚡ High-performance Waybar modules written in Zig for efficient system monitoring

License

Notifications You must be signed in to change notification settings

erffy/zig-waybar-contrib

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

zig-waybar-contrib License Stars Issues Last Commit
High-performance Waybar modules written in Zig for efficient system monitoring

Overview

zig-waybar-contrib is a collection of high-performance custom modules for Waybar, built using the Zig.

  • Blazingly Fast: Minimal startup time and runtime overhead.
  • Memory Safe: Leveraging Zig's safety features to prevent common crashes and leaks.
  • Zero Dependencies: Statically linked binaries that run anywhere without runtime interpreters.
  • Deeply Configurable: Simple, type-safe configuration using ZON (Zig Object Notation).

Whether you need to monitor precision fan speeds, track compilation latency with pings, or watch your memory usage without eating it up, zig-waybar-contrib has you covered.

Community

Join our Discord server for updates, support and discussion:
Discord

Modules

Module Description
CPU Displays per-core CPU usage
Fan Monitors fan speeds
GPU Monitors GPU usage and temperature
Memory Reports RAM usage and statistics
Network Monitors network traffic and speed
Ping Measures network latency
Updates Tracks system package updates

See MODULES for detailed documentation on each module.

Installation

Repology Repology

Note

To try the Nightly versions, follow Script Installation section.
To try the Beta versions, install the zig-waybar-contrib-beta-bin package from AUR

Quick Installation (AUR)

You can easily install the latest version from the AUR.

# Using paru
paru -S zig-waybar-contrib

# Using yay
yay -S zig-waybar-contrib

Script Installation

Note

This script doesn't need root permissions.

The installation script automates cloning, building, and installing.

bash -c "$(curl -fsSL https://codeberg.org/erffy/zig-waybar-contrib/raw/branch/0.16.x-staging/install.sh)"

This script installs into your $HOME directory ($HOME/.local/share/zig-waybar-contrib) and places its binaries in $HOME/.local/bin.

Manual Build (From Source)

To build from source, you need Zig installed (check build.zig for version requirements).

git clone https://codeberg.org/erffy/zig-waybar-contrib.git
cd zig-waybar-contrib
zig build -Drelease

Binaries will be available in zig-out/bin/.

Configuration

Add the modules to your Waybar configuration. You can include the provided config file or define modules manually.

Method 1: Include Config

{
  // Load module configurations from zig-waybar-contrib
  "include": [
    "/usr/share/zig-waybar-contrib/config.jsonc", // if you installed from aur
    "~/.local/share/zig-waybar-contrib/config.waybar.jsonc" // if you installed with script
  ],

  "modules-right": [
    "custom/updates",
    "custom/memory",
    "custom/ping",
    "custom/cpu",
    "custom/fan"
  ]
}

Method 2: Manual Definition

See config.waybar.jsonc for the default configuration values.

Contributing

See CONTRIBUTING

Acknowledgments

  • 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!
Join our Discord for support and updates!

This project is licensed under the GNU General Public License v3.0. See LICENSE for details.