Skip to main content
Topic: [SOLVED] How to get email notifications on a TWM? (Read 389 times) previous topic - next topic
0 Members and 2 Guests are viewing this topic.

[SOLVED] How to get email notifications on a TWM?

Hi all!

I recently have been working at a startup and I've set it up so that I get email notifications anytime somebody posts on a community message board regarding the project. This is fine if I'm away from my computer and my phone pings me, but I'd like to set it up so that I can turn that off on my phone when sitting at my computer and rather get notifications show up on my desktop via dunst.

This is possible by leaving thunderbird open, but I was wondering if there's a way I can monitor my mail from my desktop without leaving thunderbird open?

Preferably I'd have dunst send me a very simple message that I have a new email message even when thunderbird is closed. I don't have any bar on my twm setup, so dunst is the only way I currently receive notifications.

Is this possible? I was looking around online and it does seem possible, but I'm confused as to the best way of going about achieving this. I'll continue to search, but the community here is pretty darn good at pointing me in the right direction.

Any help or advice on this topic would be greatly appreciated, and thanks in advance as always.

Re: How to get email notifications on a TWM?

Reply #1
This is possible by leaving thunderbird open, but I was wondering if there's a way I can monitor my mail from my desktop without leaving thunderbird open?

I would use conky.

https://wiki.archlinux.org/title/Conky/Tips_and_tricks#Display_number_of_new_emails
"Wer alles kann, macht nichts richtig"

Artix USE="runit openrc slim openbox lxde gtk2 qt4 qt5 qt6 conky
-gtk3 -gtk4 -adwaita{cursors,themes,icons} -gnome3 -kde -plasma -wayland "

Re: How to get email notifications on a TWM?

Reply #2
Thank you, but I'm not a big fan of conky. The only system monitoring tools I like are htop and btop. That is a nice feature of conky though I'll admit.

After experimenting with both neomutt and thunderbird, I've determined that keeping them open is the only way to receive  email notifications (and thunderbird was the only one out of the two that did so in a timely manner).

Instead, I did a bit of research into my tiling window manager, bspwm, and found a short script that allows me to toggle a single window on a workspace to "hidden". This is good enough for me for now. I'm marking this as solved and moving on.

Thanks again!

Re: [SOLVED] How to get email notifications on a TWM?

Reply #3
there's a package called mutt-wizard-git

it has a script called "mailsync". it does all you want. you can run this is script with a cronjob.

you can get number of unread mail like this

Code: [Select]
unread="$(find "${XDG_DATA_HOME:-$HOME/.local/share}"/mail/*/[Ii][Nn][Bb][Oo][Xx]/new/* -type f | wc -l 2>/dev/null)"