Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:03:07

0001 #!/bin/sh
0002 if [ $# -ne "1" ] 
0003 then
0004     echo Generates XML mapping files for HCAL objects
0005     echo Usage $0 version_name
0006     exit 1
0007 fi
0008 
0009 version=$1
0010 
0011 # redundant variables
0012 CORAL_AUTH_USER=blah
0013 CORAL_AUTH_PASSWORD=blah
0014 export CORAL_AUTH_USER
0015 export CORAL_AUTH_PASSWORD
0016 
0017 #for object in HcalPedestals HcalPedestalWidths HcalGains HcalGainWidths HcalQIEData HcalElectronicsMap HcalChannelQuality
0018 for object in HcalPedestals HcalPedestalWidths HcalGains HcalGainWidths HcalElectronicsMap HcalChannelQuality
0019 do
0020     echo processing $object...
0021     defaultname=$object-mapping-cmsdefault.xml
0022     outname=$object"-mapping-custom_$version.xml"
0023     rm -f $defaultname $outname
0024     ../../Utilities/bin/create_default_mapping -v $object CondFormatsHcalObjects
0025 # now modify it according to https://uimon.cern.ch/twiki/bin/view/CMS/O2O-HOWTO
0026     tablename=`echo $object | sed 's/[a-z]/\u&/g'`
0027     cat $defaultname | sed 's/id_columns="ID"/id_columns="IOV_VALUE_ID"/g' | sed 's/ID_ID/IOV_VALUE_ID/g' | sed 's/MITEMS_//g' | sed 's/version="cmsdefault"/version="'$version'"/g' > $outname
0028 done