Go to file
2023-04-02 16:34:37 -05:00
data ammended readme and revised example config 2023-04-02 16:34:37 -05:00
dist fixed directory name, made installable 2023-04-02 16:06:37 -05:00
easyconf_lemonbar fixed directory name, made installable 2023-04-02 16:06:37 -05:00
.gitignore removed poetry lockfile 2023-04-02 14:46:36 -05:00
install.sh fixed directory name, made installable 2023-04-02 16:06:37 -05:00
LICENSE wrapped LICENSE at 80 chars 2023-02-10 16:06:11 -06:00
poetry.toml class groundwork laid 2023-03-11 19:19:26 -06:00
pyproject.toml class groundwork laid 2023-03-11 19:19:26 -06:00
README.md ammended readme and revised example config 2023-04-02 16:34:37 -05:00
run.sh fixed directory name, made installable 2023-04-02 16:06:37 -05:00
uninstall.sh fixed directory name, made installable 2023-04-02 16:06:37 -05:00

easyconf-lemonbar (eclb)

A python script to easily configure lemonbar.

Installation

To install the latest release:

git clone --depth 1 --branch latest https://git.noahsw.xyz/noah/easyconf-lemonbar.git
cd easyconf-lemonbar
sudo sh install.sh

Configuration and Usage

Config File

After installing, you will need to copy the example config file to your XDG_CONFIG_HOME.

cp /usr/local/share/doc/easyconf-lemonbar/example_config.yml ${HOME}/.config/easyconf-lemonbar.yml

This example file is very heavily commented. Almost all the info you will need is contained in the file.

Signals

You may update individual modules by sending a real-time signal to the easyconf-lemonbar process. First, in the module configuration, specify which signal to listen for, e.g.

# Display a random number, and only update when we recieve the RTMIN+1 signal.
- name: "random"
  command: "python -c 'from random import randrange; print(randrange(1000))'"
  refresh: 0
  signal: 1

In the example above, the refresh is 0. This means that the module will never refresh on its own; it will wait for the RTMIN+1 signal. You may also configure your module to both refresh on a time interval AND listen for a signal.

Unfortunately, to send the signal, you cant just pkill easyconf-lemonbar. You have to read the PID from eclb's pidfile. I would recommend creating an alias in your shell as shown below.

alias eclb_kill="cat /run/user/${UID}/easyconf-lemonbar.pid | xargs kill"
eclb_kill -RTMIN+1

This will refresh the module that is listening for signal 1. To kill eclb completely, just run eclb_kill (after setting the above alias).