Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

do-not-disturb is still disturbing #468

Closed
ghost opened this issue Jul 20, 2023 · 6 comments
Closed

do-not-disturb is still disturbing #468

ghost opened this issue Jul 20, 2023 · 6 comments

Comments

@ghost
Copy link

ghost commented Jul 20, 2023

I must be missing something.

Following man 5 mako, I've put:

[mode=do-not-disturb]
invisible=1

in my config file.

Then I add the mode with makoctl mode -a do-not-disturb.

But I'm still receiving all the notifications.

@dR3b
Copy link

dR3b commented Aug 4, 2023

Same! I tried it this way:

~ » makoctl dismiss -a
~ » notify-send "test"

The dialog box with: "test" appeared in the corner...

Arch Linux: extra/mako 1.8.0-1

@hendursaga
Copy link

Does makoctl mode list "do-not-disturb" or no?

@parisni
Copy link

parisni commented Feb 8, 2024

Hi same here.

Does makoctl mode list "do-not-disturb" or no?

only returns default.

@parisni
Copy link

parisni commented Feb 8, 2024

made it work:

# added to config
[mode=hide]
invisible=1

makoctl mode -s hide # hide the notif
makoctl mode -r hide # restore notif + show the hidden notif

maybe the dash in do-not-disturb, i don't know

Also, in the man 5 mako:

makoctl mode ‐a do‐not‐disturb will hide all notifications, makoctl mode ‐r do‐not‐disturb will show them again.

Should be :

makoctl mode ‐s do‐not‐disturb will hide all notifications, makoctl mode ‐r do‐not‐disturb will show them again.

@guttermonk
Copy link

@parisni thank you! That was a big help.

I wrote a short script to toggle "do not disturb" on and off:

#!/bin/bash

# Toggle DND
	if [ "$(makoctl mode)" == "dnd" ]; then
	# DND OFF
		makoctl mode -r dnd && echo "DND Mode OFF"
	else
	# DND ON
		makoctl mode -s dnd && echo "DND Mode ON"
	fi

Here's the module:

"custom/mako": {
    "on-click": "~/.config/hypr/scripts/notifications-toggle-dnd",
	"format": "DND {icon}",
	"format-icons": {
      "activated": " ",
      "deactivated": " ",
	},
    "tooltip": true,
	"tooltip-format": "Toggle DND on/off",
},

Does anyone know how to make the toggle icons work?

emersion added a commit that referenced this issue May 10, 2024
Instead of silently ignoring extra arguments, print an error to
help users.

References: #468
@emersion
Copy link
Owner

Beware, the copy-pasted text from the man page contains special Unicode characters: in the copy-pasted text above "‐" is U+2010, but the correct ASCII character to use "-" is U+002D. getopts will parse U+2010 as a positional argument instead of an option and as a result it will get ignored.

I've pushed 6373655 to print an error instead of silently ignoring unused positional arguments.

Note, a toggle flag has been added in #502.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants