Changeset 30424


Ignore:
Timestamp:
03/21/16 20:05:23 (5 years ago)
Author:
ak19
Message:

Dr Bainbridge improved the code so that the script always gets the latest rke.out filename of today to process (and it processes both that and the associated uploaded binary).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • other-projects/expeditee-release-kits/process_incoming.sh

    r30410 r30424  
    1111# uploaded.
    1212
     13origdir=`pwd`
     14
     15# default binary directory to where this script lives, then go there
     16# http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in
     17bindir=`dirname "$0"` #dirname "$(readlink -f "$0")"
     18pushd $bindir
    1319
    1420# http://stackoverflow.com/questions/1401482/yyyy-mm-dd-format-date-in-shell-script
     
    1824# the file uploaded is the one with the latest timestamp
    1925# ls -rt lists files by time, then get the last one
     26# the file pattern looks for rke-currentdate-<OS>.out files
    2027#incoming_file=$1
    21 incoming_file=`ls -rt *$date* 2>/dev/null | tail -n 1`
    22 #echo "Hello world. Incoming file: $incoming_file" >> out.txt
     28incoming_file=`ls -rt rke-*$date*.out 2>/dev/null | tail -n 1`
     29#echo "Incoming file: $incoming_file" >> out.txt
     30
     31# http://stackoverflow.com/questions/21620406/how-do-i-pause-my-shell-script-for-1-second-before-continuing
     32#sleep 2m
    2333
    2434# arrays
     
    103113#ls -la "._Expeditee*dmg"
    104114rm -rf "._Expeditee*dmg"
     115
     116popd
Note: See TracChangeset for help on using the changeset viewer.