#!/bin/ksh93 PKG=$1 VERSIONS=( 0.5.11-0.175.1.1.0.4.0 0.5.11-0.175.1.0.0.24.2 0.5.11-0.175.0.13.0.4.0 0.5.11-0.175.0.12.0.4.0 0.5.11-0.175.0.11.0.4.1 0.5.11-0.175.0.10.0.5.0 0.5.11-0.175.0.9.0.5.0 0.5.11-0.175.0.8.0.5.0 0.5.11-0.175.0.7.0.5.0 0.5.11-0.175.0.6.0.6.0 0.5.11-0.175.0.5.0.5.0 0.5.11-0.175.0.5.0.4.0 0.5.11-0.175.0.4.0.6.0 0.5.11-0.175.0.4.0.5.0 ) integer I MAX=${#VERSIONS[@]}-1 OLDIFS="$IFS" NE=${VERSIONS[$MAX]} IFS='.' typeset -ia NV=( ${NE#*-} ) OV IFS="$OLDIFS" NR=${VERSIONS[$MAX]%-*} NR=${NR##*.} NS="${NR}.${NV[2]}.${NV[3]}.${NV[5]}" for (( I=$MAX-1; I >= 0; I-- )); do OE=$NE OV=$NV OS=$NS NE=${VERSIONS[$I]} IFS='.' NV=( ${NE#*-} ) IFS="$OLDIFS" NR=${VERSIONS[$I]%-*} NR=${NR##*.} NS="${NR}.${NV[2]}.${NV[3]}.${NV[5]}" print $HOME/etc/ipsCompare.sh -o $OE -n $NE -S /tmp/ips $PKG ">" "${OS}-${NS}-diff.txt" $HOME/etc/ipsCompare.sh -o $OE -n $NE -S /tmp/ips $PKG >"${OS}-${NS}-diff.txt" print $HOME/etc/ipsCompare.sh -O /tmp/ips.old -N /tmp/ips.new -a ">" "${OS}-${NS}-full-diff.txt" $HOME/etc/ipsCompare.sh -O /tmp/ips.old -N /tmp/ips.new -a >"${OS}-${NS}-full-diff.txt" print $HOME/etc/ipsCompare.sh -O /tmp/ips.old -N /tmp/ips.new -A ">" "${OS}-${NS}-all.txt" $HOME/etc/ipsCompare.sh -O /tmp/ips.old -N /tmp/ips.new -A >"${OS}-${NS}-all.txt" done