Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am on tmux, with mutt in an inactive window. If IMAP flags change on a message through external means, I see the visual bell and the status bar changes, drawing my attention to the e-mail client. That works well.

What I would like to do but still can't get to work is:

  • Get a proper notification about incoming e-mail whilst in another tmux window
  • Never get notifications later than 5 minutes from their arrival, possibly fine-tuning this interval

I use Gmail over IMAPS.

share|improve this question
up vote 4 down vote accepted

You could call a small script from your tmux status bar that updates with any new mail:

# Set maildirs

find $maildirs -type f | wc -l

And in your .tmux.conf:

set -g status-right "#[fg=yellow,bright]Mail: #(tmuxmail) ..."

This count will be updated according to the status-interval value, eg.,: set -g status-interval 1

share|improve this answer
I am accepting even if this is for local mail, not for Gmail over IMAPS... – Robottinosino Oct 16 '12 at 5:53

You may look at tmux-powerline If you don't like to solarize your tmux colorscheme as I do, you may look at mailcheck that tmux-powerline use to check email.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.