The file is currently at ~controls/sballmer/bin/checkCompiledModel Usage: checkCompiledModel mymodel.mdl Example 1: ========== controls@opsws3:~ 0$ ./sballmer/bin/checkCompiledModel SIXOSEM_T_STAGE_MASTER.mdl SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1susmc1 | SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1susmc3 | SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1susomc | SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1suspr2 | SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1suspr3 | SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1sussr2 | SIXOSEM_T_STAGE_MASTER.mdl | LastModifiedDate "Thu Oct 11 10:00:18 2012" | h1sussr3 | Example 2: ========== controls@opsws3:~ 0$ ./sballmer/bin/checkCompiledModel h1isiham5.mdl h1isiham5.mdl | LastModifiedDate "Mon Aug 5 14:22:07 2013" | h1isiham5 | Name "SVN $Id: h1isiham3.mdl 3807 2013-02-13 23:39:29Z hugo.paris@LIGO.ORG $" Example 3: ========== controls@opsws3:~ 0$ ./sballmer/bin/checkCompiledModel MC_MASTER.mdl MC_MASTER.mdl | LastModifiedDate "Thu Jan 24 13:17:13 2013" | h1susmc2 | MC_MASTER.mdl | LastModifiedDate "Thu Jan 24 13:17:13 2013" | h1susprm | MC_MASTER.mdl | LastModifiedDate "Thu Jan 24 13:17:13 2013" | h1sussrm | Example 4: ========== controls@opsws3:~ 0$ ./sballmer/bin/checkCompiledModel hepitemplate.mdl hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpibs | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpietmx | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpietmy | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiham1 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiham2 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiham3 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiham4 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiham5 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiham6 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiitmx | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1hpiitmy | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1isiham2 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1isiham3 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1isiham4 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1isiham5 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" hepitemplate.mdl | LastModifiedDate "Tue Feb 12 09:30:54 2013" | h1isiham6 | Name "SVN $Id: hepitemplate.mdl 3774 2013-02-12 17:32:42Z vincent.lhuillier@LIGO.ORG $" Code: ===== #!/bin/bash # usage: # checkCompiledModel# # makes a list of all front end codes that use # and lists the LastModifiedDate of , as well as # the SVN Id string # # useful for # - figuring out which model uses which library # - what version things are compiled agains # # Author: Stefan Ballmer, 2013/10/20 # parameters model=$1 TEMPDIR=/tmp/tempDir_checkCompiledModel files='ls /opt/rtcds/${site}/${ifo}/target/${ifo}*/src/sources.tar.gz' # make temporary directory mkdir $TEMPDIR cd $TEMPDIR for f in $files do g='echo $f | sed 's/// /g' | awk '{print $6}'' # echo checking $g mkdir $g tar -xf $f -C $g data='find $g -name $model' for d in $data do lmod='grep LastModifiedDate $d' svnstr='grep "SVN $Id" $d' echo $model | $lmod | $g | $svnstr done done cd .. rm -rf $TEMPDIR