changeset 427:fd948111f8ea prerelease

Compatibility: mingw's default date format is not parsed correctly by Debian; stat is not necessarily available
author Giulio Moro <giuliomoro@yahoo.it>
date Thu, 16 Jun 2016 18:09:59 +0100
parents 4c2588930b0a
children b27676f871d7
files scripts/update_board.sh
diffstat 1 files changed, 3 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/update_board.sh	Thu Jun 16 18:08:26 2016 +0100
+++ b/scripts/update_board.sh	Thu Jun 16 18:09:59 2016 +0100
@@ -71,12 +71,11 @@
 
 
 # Find location of this script so we can locate the rest of the files
-SCRIPTPATH=$(readlink "$0")
-SCRIPTDIR=$(dirname "$SCRIPTPATH")
+SCRIPTDIR=$(dirname "$0")
 [ -z "$IDE_FOLDER" ] && IDE_FOLDER=$SCRIPTDIR/../../bela-ide/
 
 
-ssh $BBB_ADDRESS "date -s '`date`' > /dev/null; stat $BBB_BELA_HOME &>/dev/null" && DESTINATION_EMPTY=0 || DESTINATION_EMPTY=1
+ssh $BBB_ADDRESS "date -s \"`date '+%Y%m%d %T'`\" > /dev/null; stat $BBB_BELA_HOME &>/dev/null" && DESTINATION_EMPTY=0 || DESTINATION_EMPTY=1
 
 if [ $DESTINATION_EMPTY -eq 0 ];
 then
@@ -146,7 +145,7 @@
 
 #-------------
 #Installing IDE
-stat $IDE_FOLDER/scripts/setup_IDE.sh &> /dev/null
+ls $IDE_FOLDER/scripts/setup_IDE.sh &> /dev/null
 if [ $? -eq 0 ]
 then
   cd $IDE_FOLDER/scripts && ./setup_IDE.sh -y