LinuxCommandLibrary

makoctl-mode

Manage mako notification modes

TLDR

List all currently active modes

$ makoctl mode
copy

Add a mode
$ makoctl mode -a [do-not-disturb]
copy

Remove a mode
$ makoctl mode -r [do-not-disturb]
copy

Toggle a mode (add if absent, remove if present)
$ makoctl mode -t [do-not-disturb]
copy

Set specific modes, replacing all current modes
$ makoctl mode -s [mode1 mode2 ...]
copy

SYNOPSIS

makoctl mode list
makoctl mode add <mode>
makoctl mode rm <mode>
makoctl mode activate <mode>
makoctl mode deactivate

PARAMETERS

list
    Lists all currently configured notification modes.

add <mode>
    Adds a new notification mode named <mode>. This makes the mode name available for configuration in Mako's config file.

rm <mode>
    Removes the notification mode named <mode>. If the mode is active, it will be deactivated first.

activate <mode>
    Activates the notification mode named <mode>. Any previously active modes will be deactivated.

deactivate
    Deactivates all currently active notification modes, returning Mako to its default behavior.

DESCRIPTION

The makoctl mode subcommand is used to control and manage how Mako, the Wayland notification daemon, displays notifications across different display modes.

Modes allow users to define distinct sets of notification rules (e.g., showing all, hiding some, or muting entirely) that can be toggled on or off, often based on specific contexts like presenting, gaming, or general work. This command enables listing available modes, adding new ones, removing existing ones, activating a particular mode, or deactivating all active modes.

It provides flexibility in customizing notification behavior dynamically without restarting the daemon or manually editing configuration files. This dynamic control is essential for adapting notification behavior to various user activities and preferences, ensuring a less disruptive computing experience on Wayland systems.

CAVEATS

This command assumes you are referring to the makoctl mode subcommand of the Mako Wayland notification daemon, as 'makoctl-mode' is not a standard standalone Linux command.

For modes to have an effect, their behavior (e.g., hiding notifications, changing style) must be defined within Mako's configuration file (typically ~/.config/mako/config). The makoctl mode command only manages the active state of these named modes.

Mako daemon must be running for these commands to function and for changes to take effect.

CONFIGURATION FOR MODES

To make a mode effective, specific rules must be defined for it in Mako's configuration file, typically ~/.config/mako/config. For example, a [mode=dnd] section could specify invisible=1 to hide all notifications when "dnd" mode is active. Without corresponding configuration, adding or activating a mode will have no visible effect on notification behavior.

INTEGRATION WITH WAYLAND COMPOSITORS

The makoctl mode command is commonly integrated into Wayland compositor configurations (e.g., Sway, Hyprland) using keybindings or status bar scripts. This allows users to quickly toggle notification modes based on their current activity, enhancing workflow efficiency and reducing distractions.

HISTORY

Mako is a relatively modern Wayland-native notification daemon, designed to be lightweight and highly configurable. The makoctl utility, including its mode subcommand, was introduced as part of Mako's development to provide a dynamic way for users and scripts to interact with and control the daemon's behavior without needing to restart it or directly manipulate configuration files. This capability is crucial for environments where notification display needs to adapt quickly, such as during screen sharing or gaming sessions, allowing for immediate state changes.

SEE ALSO

mako(1), makoctl(1)

Copied to clipboard