[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: The updates firehose



Don Russell (fedora drussell dnsalias com) said: 
> What I *would* like (just started thinking about it) is a procmail 
> recipe to divide the  announcement e-mails into "installed" and "not 
> installed" packages.

Well, there's no guarantee that you're reading the mail on the
box in question, etc. Perhaps something utilizing yum-updatesd
might be better?

> For example... I received an e-mail with this subject:
> Fedora 7 Update: xorg-x11-server-1.3.0.0-8.fc7
> 
> Thats great... very consistent subject patterns, but from a programming 
> point of view, how do I know where the program name ends (so I can use 
> it with an rpm -q command to see if it is installed), and where the 
> version number starts (so I can compare it with the results of rpm -q)? 
> It would help is there was a blank between program name and version 
> number... or even more explicit:
> Fedora 7 Update: xorg-x11-server Version: 1.3.0.0-8.fc7

echo "xorg-x11-server-1.3.0.0-8.fc7" | awk -F '-' '{ print gensub("-"," ",NF-2) }'

There are certainly simpler ways.

Bill


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]