3

here are my notifications and I would like each notification to replace the one before it

by the way I am using dunst for my notifications

enter image description here

Rui F Ribeiro
  • 55,929
  • 26
  • 146
  • 227
Neo Mosaid
  • 363
  • 1
  • 5
  • 15

3 Answers3

3

You should use dunstify instead of notify-send, because first one allows you to use notification ID and replace older notifications with newer ones. Here is link to info about dunstify, and link to example of creating volume level indicator.

3

As noted in this github comment: dunst now supports stack-tag feature. You simply need to assign custom tag to your notification like so:

notify-send --hint=string:x-dunst-stack-tag:test SUMMARY BODY

where test is an example of a custom tag.

im.pankratov
  • 131
  • 3
1

man dunst:

   stack_duplicates (values: [true/false], default: true)
       If set to true, duplicate notifications will be stacked together
       instead of being displayed separately.

       Two notifications are considered duplicate if the name of the
       program that sent it, summary, body, icon and urgency are all
       identical.

   hide_duplicates_count (values: [true/false], default: false)
       Hide the count of stacked duplicate notifications.
Ipor Sircer
  • 14,376
  • 1
  • 27
  • 34