On 23:54 31 Jan 2002, Brian Clark <[EMAIL PROTECTED]> wrote:
| What I'm asking is, is there a way to query an external file full of
| addresses in order to determine if the message should be a certain color
| in the index?
| 
| IOW, I'm trying to replace these (a lot more than 3):
| 
| color index yellow default "~f feefee ~N"
| color index yellow default "~f geegee ~N"
| color index yellow default "~f heehee ~N"
| 
| With one line that gets the list from a file (via grep?).

A wrapper for mutt? Which generates a line like this:

        color index yellow default "~f (feefee|geegee|heehee) ~N"


Again we fall into the "things too rich for mutt" category.

Idea: how about:

        an "eval" which ran a mutt string, eg:
                eval `cmd-to-make-the-above-color-command`

BTW, to make an OR like the above one of my shell scripts goes:

        ptn=`echo "$*" | tr ' ' '|'`
        egrep "($ptn)" ...

i.e. echo the words, turn space into '|', put in () and use.
-- 
Cameron Simpson, DoD#743        [EMAIL PROTECTED]    http://www.zip.com.au/~cs/

My housemates have a "Dumbfucks Killed by Avalanche" thermometer next
to the television. They're hoping for 30 this winter, and nothing seems
to get them a-smilin' more than watching the 10:00 news and grabbing
that red magic marker.  - Dan Hillman

Reply via email to