Hyprland and notifications with mako

Here’s another post on how to get started with Hyprland.

This time, we’ll see how to configure notifications with mako, a lightweight notification daemon for Wayland, which also works with Hyprland. (you might also want to consider and experiment with an alternative: dunst).

If you followed my previous tutorials, you have no notification daemon installed. You can verify that by running the following command (to issue a notification manually) and by looking at the resulting errors:

Let’s install “mako”:

The nice thing about mako is that you don’t need to start it as a service manually: the first time a notification is emitted, mako will run automatically.

Let’s try to run the above notification command above, and this time, we see the pop-up, by default, on the right top corner of the screen:

You have to click the pop-up to make it disappear.

Each time a program emits a notification, mako will show it. For example, Thunderbird, Firefox, and Chrome will emit notifications that mako will display.

Let’s do some further experiments by manually emitting notifications:

will lead to

You can see that the first argument is the title and formatted in boldface.

You can have a look at mako’s manual (5) about its configuration file and where it is searched for:

An example configuration, usable as a starting point, can be found here: https://github.com/emersion/mako/wiki/Example-configuration.

Each time you modify the configuration, you must reload mako by using one of the following commands:

or

With that example configuration, we can emit a few notifications with different “urgencies”, and see the different colors and positions of the boxes:

If you use EndeavourOS, you will get notifications about new updates and when a reboot is required after a system update (the latter is a “critical” notification):

That’s all! Not too difficult, isn’t it? 🙂

Stay tuned for more posts about Hyprland. 🙂

One thought on “Hyprland and notifications with mako

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.