Testen ob directory leer?
Andre Landwehr
andre.landwehr at gmx.net
Wed Nov 3 09:55:03 CET 1999
On Wed, Nov 03, 1999 at 09:45:08AM +0100, Peter Lohmann wrote:
> Wie kann ich am besten testen ob eine Directory leer ist, und falls nicht einen
> Befehl ausführen?
> Konkret: Computer soll script ausführen, wenn /var/spool/mqueue nicht leer ist.
if [ `ls /var/spool/mqueue/|wc -l` -gt 0 ]; then echo hallo; fi
statt echo hallo kannst du auch dein Script aufrufen
Gruß
Andre
More information about the Linux
mailing list