Tugger the SLUGger!SLUG Mailing List Archives

[SLUG] scripting question


I've written a small script that archives email - it works, but I was
wondering if there's any better way to write it (apart from using
another language).

The script is:

> for i in z_bak:7 root:14 y_spam_definite:56 ; do
>     mydir=${i%:*}
>     mydays=${i#*:}

$mydir is the directory to cleanup, $mydays is the # of days I want to
keep email. Is there any better way of writing the for loop to go thru
the 2 sets of values?

-- 
Sonia Hamilton. GPG key A8B77238.
.
One OS to rule them all, One OS to find them.
One OS to call them all, And in salvation bind them.
In the bright land of Linux, Where the hackers play.