Thanks to visit codestin.com
Credit goes to github.com

Skip to content

netfri25/bread

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bread

simple, easily composable, non-interactlable, controlled from stdin, wayland status bar.

"a bar that reads" (b read).

Specifications

  • non-interactable (by design)
  • controlled from stdin with simple but powerful attributes
  • single threaded (by design)
  • efficient polling system
  • works on multiple monitors (and doesn't crash when monitor disconnects)
  • for wlroots compositors

Build Dependencies

Note

doesn't need wayland development packages

Getting started

Installation

if you don't have Rust on your system, install it

cargo install --git https://github.com/netfri25/bread

Usage

my-script | bread --font "Iosevka-Custom"

where my-script is your own script, that generates content for bread to display

if you don't feel like creating your own script, consider using bread-content

Customization

bread only renders information given in stdin. this means that you need to create your own program/script that can gather the information that you want to render and generate the output to be parsed by bread

a reference program can be found here, which is the program that I use in my own setup.

bread is able to parse the following attributes:

%{l} - left section
%{c} - center section
%{r} - right section

%{F:[AA]RRGGBB} - foreground color
%{B:[AA]RRGGBB} - background color

%{R:WxH} - ramp (width x height in pixels)

everything else is parsed as plain text.

bread keeps track of the last speficied attributes, which means you don't have to specify the section/color before each text content or a ramp.

Why?

I want to:

  • learn wayland
  • create my own status bar
  • separate rendering from information gathering
  • have flexible design
  • be the same on all monitors
  • be single threaded with efficient polling

the bar that made me almost satisfied is zelbar, and it encouraged me to create my own. the only things I had issues with while trying out zelbar is that I wasn't able to draw boxes with a defined width and height (which I like for cpu usage), and it crashed if I closed the monitor it was on (which I do from time to time, because I use a laptop).

TODO

  • multi monitor rendering
    • test with another monitor
  • input parsing
  • rendering
  • async polling
  • mention the other project that is able to provide content, as an example
  • cli arguments for simple config
    • default fg/bg colors
    • height
    • position (top/bottom)
    • font
    • font size
    • specific monitor (or all monitors by default)
  • write a manpage

Special Thanks

zelbar, which inspired this project.

wayland-rs, which provides a really comfortable design for working with wayland.

wayland for providing an amazing protocol and architecture!

About

status bar for wayland

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages