[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [monitoring-like] would like to be warned when I have mail (fetchmai
From: |
Gerhard Siegesmund |
Subject: |
Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c) |
Date: |
Thu, 29 Sep 2005 08:57:14 +0200 |
User-agent: |
Mutt/1.5.11 |
Hello Michael
> It should work if you use just echo, as this is a shell builtin.
> If that 'echo something' is an external command or a pipe you have
> to use 'echo something || exit 1'.
> How exactly does the script look like?
Here is the script:
------------------------------------------------------------------------
#!/bin/sh
# Holt sich von fetchmail die Anzahl Mails und gibt diese aus.
#
# Author: Gerhard Siegesmund <address@hidden>
FETCHMAIL='/usr/bin/fetchmail'
while true; do
$FETCHMAIL -c | sed -e 's/.* \([0-9]*\) messages (\([0-9]*\) seen.*/\1 -
\2/g' | bc
sleep 60
done
------------------------------------------------------------------------
Any suggestions?
--
cu
--== Jerri ==--
Homepage: http://www.jerri.de/ ICQ: 54160208
Public PGP Key: http://www.jerri.de/jerris_public_key.asc
signature.asc
Description: Digital signature
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), (continued)
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Will Maier, 2005/09/27
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Michael Schroeder, 2005/09/28
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Gerhard Siegesmund, 2005/09/28
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Will Maier, 2005/09/28
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Gerhard Siegesmund, 2005/09/29
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Michael Schroeder, 2005/09/28
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Gerhard Siegesmund, 2005/09/29
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c),
Gerhard Siegesmund <=
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Aaron Griffin, 2005/09/28
- Re: [monitoring-like] would like to be warned when I have mail (fetchmail -c), Gerhard Siegesmund, 2005/09/29