Changeset 27540

Show
Ignore:
Timestamp:
04.06.2013 18:23:39 (6 years ago)
Author:
ak19
Message:

1. Reports better sent to the greenstone mail id 2. Need to import with OIDtype set to hashing on the full filename, to generate stable doc ids. This is how the model collections are generated, with which the locally built ones are to be compared. 3. Need to ensure the upload directory exists.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • other-projects/nightly-tasks/diffcol/trunk/task

    r27536 r27540  
    77export DATA_DIR=$TASK_HOME/diffcol-data 
    88export UPLOAD_DIR=$TASK_HOME/diffcol-reports 
    9 export MONITOR_EMAIL=anupama@waikato.ac.nz 
     9export MONITOR_EMAIL=greenstone_team@cs.waikato.ac.nz 
    1010 
    1111#check key environment vars are set 
     
    181181 
    182182        #import 
     183        #Ensure the OIDtype for importing is hash_on_full_filename 
     184        # "to make document identifiers more stable across  
     185        # upgrades of the software, although it means that  
     186        # duplicate documents contained in the collection are no 
     187        # longer detected automatically." 
    183188        echo $collection' - Importing:' 
    184189        echo "<import>" >> $xmlout 
    185         import.pl $collection -removeold 
     190        import.pl -OIDtype hash_on_full_filename $collection -removeold 
    186191        echo "</import>" >> $xmlout  
    187192        echo "done" 
     
    221226    fi 
    222227    echo "done" 
    223  
    224228} 
    225229 
    226230function upload() { 
    227     scp $DATA_DIR/*.xml $DATA_DIR/*.html $UPLOAD_DIR 
     231    # ensure the upload directory exists  
     232    # before trying to transfer the xml and html files across 
     233    if [ ! -d "$UPLOAD_DIR" ]; then 
     234    mkdir -p "$UPLOAD_DIR"; 
     235    fi 
     236 
     237    scp $DATA_DIR/*.xml $DATA_DIR/*.html $UPLOAD_DIR 
    228238} 
    229239