You are not logged in.

#1 2022-10-21 06:01:14

kriansa
Member
Registered: 2019-01-26
Posts: 5

wmcompanion - desktop environment features to your wm

wmcompanion is an automation tool that helps connecting system events to user-scriptable actions in Python so you can easily implement more advanced features to your minimalist tiling window manager based desktop.

See a snippet of configuration code that maybe speaks for itself:

@on(BluetoothRadioStatus)
@use(Polybar)
async def bluetooth_status(status: dict, polybar: Polybar):
    """
    Show the bluetooth status icon on Polybar
    This requires you to setup a polybar module using `custom/ipc` as the type
    """

    icon_color = "#F2F5EA" if status["enabled"] else "#999999"
    await polybar(module="bluetooth", polybar.fmt("[bt]", color=icon_color))

Use it to empower your existing status bar, react to system-level events such as power source and device connections, customize your desktop in a centralized, scriptable fashion, then share & reuse existing configuration from others.

You can even say wmcompanion is a sort of "Python Hammerspoon", but it obviously lacks the maturity and feature set of the latter. As of now, wmcompanion works on GNU/Linux, but porting it to BSDs/Mac wouldn't be that hard.

As of the first public release, you can use it to react to events such as the following:

  • Audio input/output levels

  • Bluetooth state

  • Kbdd keyboard layout

  • NetworkManager connection status

  • NetworkManager Wi-Fi status

  • Dunst notification paused state

  • Power events such as returning from sleep, power source and battery levels

  • X11 display state

  • X11 input device (mice/keyboard) state

I advise you to take a look at the README and the examples so you can get inspired by what you can do.

Last edited by kriansa (2022-10-21 06:01:33)

Offline

Board footer

Powered by FluxBB