A D-Bus service that prevents the compositor/desktop environment from going idle or engaging screen savers on Wayland compositors.
Inspired by matcha for the ilde inhibition, and wl-gammarelay-rs for the D-Bus approach. Partially an attempt to play around with GitHub Copilot before the montly limits kicked in.
- D-Bus interface for programmatic control
- Wayland idle inhibit protocol support
- Starts with idle inhibition disabled by default
- Graceful shutdown on SIGINT/SIGTERM
cargo build --releasecargo run --releaseThe service will start and expose a D-Bus interface at:
- Service Name:
org.guayusa.IdleInhibitor - Object Path:
/ - Interface:
org.guayusa.Idle
The service exposes the following methods and properties:
Enable()- Enables idle inhibitionDisable()- Disables idle inhibitionToggle()- Toggles idle inhibition state (returns new state)SetInhibit(bool)- Sets idle inhibition state (true = enable, false = disable)
Status(boolean, read-only) - Current idle inhibition status
busctl --user call org.guayusa.IdleInhibitor / org.guayusa.Idle Enablebusctl --user call org.guayusa.IdleInhibitor / org.guayusa.Idle Disablebusctl --user call org.guayusa.IdleInhibitor / org.guayusa.Idle Togglebusctl --user call org.guayusa.IdleInhibitor / org.guayusa.Idle SetInhibit b truebusctl --user call org.guayusa.IdleInhibitor / org.guayusa.Idle SetInhibit b falsebusctl --user get-property org.guayusa.IdleInhibitor / org.guayusa.Idle Statusdbus-monitor --session "type='signal',interface='org.guayusa.Idle',member='StatusChanged'"busctl --user monitor org.guayusa.IdleInhibitor- Wayland compositor that supports the
zwp_idle_inhibit_manager_v1protocol - D-Bus session bus
wayland-client- Wayland protocol bindingswayland-protocols- Wayland protocol definitionszbus- D-Bus implementationtokio- Async runtimesignal-hook-tokio- Signal handlingfutures- Async utilities
This project is licensed under the MIT License.