1
1
Fork
You've already forked menubun
0
Simple config-based custom menu maker for dmenu-like programs.
  • Hare 100%
Edin Tarić 02ac1e76d6 Update for Hare 0.25.2 nomem changes
With help from Rosie K Languet <rkl@rosiesworkshop.net> - thanks!
2025年09月12日 11:06:05 +02:00
menubun.ha Update for Hare 0.25.2 nomem changes 2025年09月12日 11:06:05 +02:00
README.md readme: rename merge request to pull request 2024年05月06日 08:25:44 +02:00

menubun

menubun enables you to create custom menus for dmenu-compatible programs with a very simple configuration syntax. It's a very small program written in the Hare programming language, hence the name (even though bunnies are not hares).

Usage

menubun <configfile>

Config syntax

The configfile is written in the ini format, here's an example:

menu = fuzzel --dmenu
[entries]
Bluetooth on = bluetoothctl power on
Bluetooth off = bluetoothctl power off
Some other action = mycommand myarg "arg with spaces" another\ arg

The menu key at the root level specifies which menu program is used, in this case fuzzel --dmenu.

In the [entries] section you can then just provide label=command pairs, where the label is what will be shown in the menu and the command will be executed if you pick that menu entry. The command will be split into arguments according to shell quoting rules, so you can use quotes and/or backslash to escape strings.

Building/running from source

You can simply run the program with hare run menubun.ha or build it with hare build -o menubun menubun.ha.

Contributing

If you encounter any issues or have questions or suggestions, feel free to send me an email to unicorn@regrow.earth or open an issue.

If you want to contribute, you can send me a patch via email or open a pull request.