#!/bin/rc ### # print out ICS stages which $1 overlaps with ### #usage: span NAME base=`{awk -F* '$1 ~ /'$1'/ {print $2}' unt.g} base=`{awk -F* '$1 ~ /'$1'/ {print $2}' unt.g} top=`{awk -F* '$1 ~ /'$1'/ {print $3}' unt.g} echo awk -F* '''$4 ~ /ICS/ && $5 ~ /Stage/ && $2 >= '$base' && $3 < '$base' {print "from: " $1}''' unt.g | rc echo awk -F* '''$4 ~ /ICS/ && $5 ~ /Stage/ && $2 > '$top' && $3 <= '$top' {print "to: " $1}''' unt.g | rc