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

Re: coreutils and util-linux



FWIW, I use this script (run it in a directory of available RPMs) to
see which version-releases differ to what's installed.

#!/bin/bash
 
echo -e "Installed\\r\\t\\t\\t\\t\\tAvailable"
echo -e "---------\\r\\t\\t\\t\\t\\t---------"
for pkg in $(rpm -qa | sort)
do
  pkgname=$(echo $pkg | sed -e 's/^\(.*\)-[^-]\+-[^-]\+$/\1/')
  qpkgname=$(echo $pkgname | sed -e 's/+/\\+/g')
  file=$(ls -t1 ${pkgname}-*-*.*.rpm 2>/dev/null |
         grep "^${qpkgname}-[^-]\+-[^-]\+\.\(i386\|noarch\)" | head -n 1)
  file=${file%.*.rpm}
  [ -n "${file}" ] && [ "${pkg}" != "${file}" ] && \
    echo -e "${pkg}\\r\\t\\t\\t\\t\\t${file}"
done

Tim.
*/

Attachment: pgp00005.pgp
Description: PGP signature


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