Index: trunk/MagicSoft/Mars/datacenter/scripts/copyscript
===================================================================
--- trunk/MagicSoft/Mars/datacenter/scripts/copyscript	(revision 7863)
+++ trunk/MagicSoft/Mars/datacenter/scripts/copyscript	(revision 7866)
@@ -94,4 +94,8 @@
 fi
 
+
+ssh lapalma@apollo chmod -R g+w $transdir/* >> $scriptlog 2>&1
+
+
 cd $mars 
 
@@ -136,5 +140,5 @@
                         
       #check for each file whether it has to be processed
-      if grep "$filename: OK" $transdir/.check  >> $scriptlog 2>&1 
+      if grep -i "$filename: OK" $transdir/.check  >> $scriptlog 2>&1 
       then
          newfile=`echo $file | sed -e 's/home\/lapalma\/transfer/magic\/subsystemdata/' -e 's/ccdata/cc/' -e 's/cacodata/caco/' -e 's/drivelogs/drive/' -e 's/_/\//1' -e 's/_/\//1' `
@@ -220,6 +224,6 @@
    diff $catfile $catalog >> $diff
    #getting differences
-   ins=`cat $diff| grep '>'` #what has been inserted
-   outs=`cat $diff | grep '<'`#what has been removed
+   ins=`cat $diff | grep '>'`  #what has been inserted
+   outs=`cat $diff | grep '<'` #what has been removed
    
    #check if lines have been inserted
