more secure string operations
[u/mrichter/AliRoot.git] / TPC / scripts / makeRunList.sh
CommitLineData
47a21bc9 1#
2# Make a run list using
3# GRP and TPC HV and Altro requested
4# Output run list stored in run list
5
6prefix=/alice/data/2010/OCDB/
7
8alien_find $prefix/GRP/GRP/Data Run > grpAlien.txt
9alien_find $prefix/TPC/Calib/HighVoltage Run > hvAlien.txt
10alien_find $prefix/TPC/Calib/AltroConfig Run > altroAlien.txt
11
12cat grpAlien.txt | sed s/_/\ /g | gawk '{ print $2}' | sort > grp.txt
13cat hvAlien.txt | sed s/_/\ /g | gawk '{ print $2}' | sort > hv.txt
14cat altroAlien.txt | sed s/_/\ /g | gawk '{ print $2}' | sort > altro.txt
15
16for run in `cat hv.txt | sort`; do
17 grun=`cat grp.txt | grep -c $run`
18 arun=`cat altro.txt | grep -c $run`
19 if [ $grun -gt 0 ] && [ $arun -gt 0 ]; then
20 echo $run
21 fi
22done > run.list
23
24