Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
#!/bin/csh

./mkcfg_new120.csh ${1}

ls PYTHON_${1}/*py

if( ${status} == "0" ) then
foreach i (`ls PYTHON_${1}`)

set j=`echo ${i} | awk -F _ '{print $2}'`
set k=`echo ${i} | awk -F _ '{print $3}'`
echo ${i} ${j} ${k} ${1}
#./batchjobs120.csh ${1} ${j} ${k} `pwd` 

#bsub -q 1nh batchjobs120.csh ${1} ${j} ${k} `pwd` 
bsub -q 8nh batchjobs120.csh ${1} ${j} ${k} `pwd` 
##bsub -q 1nd batchjobs120.csh ${1} ${j} ${k} `pwd`

end
#rm -rf PYTHON_${1}
#rm -rf TXT_${1}
#rm Reco_*_cfg.py
else
echo "Problem: No jobs are created: check PYTHON_${1} directory: Notify developpers"
endif