- there is example config in examples dir
- i assume your newmail command will probably check email first but probably could do whatever
- you should have imapnotify -p or dunstify -p configured so it can display notification properly
this is my configuration scheme and i never really tried other usecases so shit might break if you want to do it your way
Run imapnotify-bash with config name as the only parameter, or put attached systemd service in your user services and start/enable it.