2022-02-10, 12:33, Alex:
I have setuped mutt to work with every account separately but then I don't get a notification when new mail is arrived in different accounts.
I use imapfilter in conjunction with mutt for this. Its configuration is Turing-complete and documented with many examples:
https://github.com/lefcha/imapfilter
As I'm not the mutt expert maybe somebody can point me to a suggestion...
If your sendmail program can read From/To headers from mail envelopes, you can save a lot of trouble because you don't have to write hooks for every account. With msmtp, mutt's configuration might look like this, for example:
set sendmail = "/usr/bin/msmtp -t --read-envelope-from --"
Be sure to set edit_headers, of course. Best of luck.