[LON-CAPA-cvs] cvs: doc /loncapafiles loncapafiles.lpml loncom/html/adm/MathJax commands loncom/html/adm/ckeditor commands loncom/html/adm/geogebra commands loncom/html/adm/jsMath FONTSVERSION commands

raeburn raeburn at source.lon-capa.org
Thu Jan 10 00:36:32 EST 2013


raeburn		Thu Jan 10 05:36:32 2013 EDT

  Added files:                 
    /loncom/html/adm/jsMath	FONTSVERSION 

  Modified files:              
    /loncom/html/adm/jsMath	commands 
    /loncom/html/adm/geogebra	commands 
    /loncom/html/adm/MathJax	commands 
    /loncom/html/adm/ckeditor	commands 
    /doc/loncapafiles	loncapafiles.lpml 
  Log:
  - Improve robustness by not relying on argument in script call in loncaapfiles.lpml - For rich text editor (ckeditor) do some clean up of old editors -- fckeditor
    and htmlarea, if installing on LON-CAPA server with long history
  - Add sleep to avoid error occasionally seen when running ./UPDATE
  - Eliminate warnings about missing directories 
  - Include FONTSVERSION for jsMath Fonts and only unzip fonts .zip file if newer
    than FONTSVERSION.
  
  
Index: loncom/html/adm/jsMath/commands
diff -u loncom/html/adm/jsMath/commands:1.4 loncom/html/adm/jsMath/commands:1.5
--- loncom/html/adm/jsMath/commands:1.4	Tue Jun 27 16:50:02 2006
+++ loncom/html/adm/jsMath/commands	Thu Jan 10 05:35:38 2013
@@ -1 +1,25 @@
-unzip -q -o -d $1 jsMath-fonts-1.3.zip
+currfontsversion=0.0
+admdir='/home/httpd/html/adm'
+jsmathdir="$admdir/jsMath"
+if [ -e $jsmathdir]
+then
+    if [ -e $jsmathdir/FONTSVERSION" ]
+    then
+        currfontsversion=`cat $jsmathdir/FONTSVERSION`
+    fi
+fi
+newfontsversion=`cat FONTSVERSION`
+comparison=`echo "$newfontsversion > $currfontsversion" | bc`
+if [ $comparison -gt 0 ]
+then
+  if [ -e $jsmathdir ]
+  then
+      rm -rf $jsmathdir
+  fi
+  unzip -q -o -d $admdir jsMath-fonts-1.3.zip
+  cp FONTSVERSION $jsmathdir/FONTSVERSION
+  chown -R www:www $jsmathdir
+  find $jsmathdir -type d -exec chmod u=rwx,go-rwx {} \;
+  sleep 1
+fi
+
Index: loncom/html/adm/geogebra/commands
diff -u loncom/html/adm/geogebra/commands:1.1 loncom/html/adm/geogebra/commands:1.2
--- loncom/html/adm/geogebra/commands:1.1	Fri Aug 17 22:52:24 2012
+++ loncom/html/adm/geogebra/commands	Thu Jan 10 05:36:00 2013
@@ -1,16 +1,24 @@
 currversion=0.0
-if [ -e "$1/VERSION" ]
+webdir='/home/httpd/html/adm/geogebra/web'
+if [ -e $webdir ]
 then
-  currversion=`cat $1/VERSION`
+    if [ -e "$webdir/VERSION" ]
+    then
+        currversion=`cat $webdir/VERSION`
+    fi
 fi
 newversion=`cat VERSION`
 comparison=`echo "$newversion > $currversion" | bc`
 if [ $comparison -gt 0 ]
 then
-  rm -rf $1/
-  tar -xvf geogebra_html5.tar.gz
-  mv web $1
-  cp VERSION $1/VERSION
-  chown -R www:www $1
-  find $1 -type d -exec chmod u=rwx,go-rwx {} \;
+  if [ -e $webdir ] 
+  then
+      rm -rf $webdir
+  fi
+  tar -xzf geogebra_html5.tar.gz
+  mv web $webdir
+  cp VERSION $webdir/VERSION
+  chown -R www:www $webdir
+  find $webdir -type d -exec chmod u=rwx,go-rwx {} \;
+  sleep 1
 fi
Index: loncom/html/adm/MathJax/commands
diff -u loncom/html/adm/MathJax/commands:1.2 loncom/html/adm/MathJax/commands:1.3
--- loncom/html/adm/MathJax/commands:1.2	Thu May 24 01:35:55 2012
+++ loncom/html/adm/MathJax/commands	Thu Jan 10 05:36:15 2013
@@ -1,17 +1,24 @@
 currversion=0.0
-if [ -e "$1/VERSION" ]
+mathjaxdir='/home/httpd/html/adm/MathJax'
+if [ -e $mathjaxdir ]
 then
-  currversion=`cat $1/VERSION`
+  if [ -e "$mathjaxdir/VERSION" ]
+  then
+      currversion=`cat $mathjaxdir/VERSION`
+  fi
 fi
 newversion=`cat VERSION`
 comparison=`echo "$newversion > $currversion" | bc`
 if [ $comparison -gt 0 ]
 then
-  rm -rf $1/
-  unzip -q -o -d $1 mathjax-MathJax-v2.0-20-g07669ac.zip
-  mv $1/mathjax-MathJax-07669ac/* $1/.
-  rm -r $1/mathjax-MathJax-07669ac
-  cp VERSION $1/VERSION
-  chown -R www:www $1
-  find $1 -type d -exec chmod u=rwx,go-rwx {} \;
+  if [ -e $mathjaxdir ]
+  then
+    rm -rf $mathjaxdir
+  fi
+  unzip -q -o -d $mathjaxdir mathjax-MathJax-v2.0-20-g07669ac.zip
+  mv $mathjaxdir/mathjax-MathJax-07669ac/* $mathjaxdir/.
+  rm -r $mathjaxdir/mathjax-MathJax-07669ac
+  cp VERSION $mathjaxdir/VERSION
+  chown -R www:www $mathjaxdir
+  find $mathjaxdir -type d -exec chmod u=rwx,go-rwx {} \;
 fi
Index: loncom/html/adm/ckeditor/commands
diff -u loncom/html/adm/ckeditor/commands:1.3 loncom/html/adm/ckeditor/commands:1.4
--- loncom/html/adm/ckeditor/commands:1.3	Fri Dec 16 19:09:28 2011
+++ loncom/html/adm/ckeditor/commands	Thu Jan 10 05:36:22 2013
@@ -1,5 +1,14 @@
 path=`pwd`
-cd $1
+htmldir='/home/httpd/html'
+if [ -e "$htmldir/fckeditor" ]
+then
+    rm -rf $htmldir/fckeditor
+fi
+if [ -e "$htmldir/htmlarea" ]
+then
+    rm -rf $htmldir/htmlarea
+fi
+cd $htmldir
 echo $path/ckeditor_3.6.2.tar.gz
-tar xzf $path/ckeditor_3.6.2.tar.gz
+tar -zxf $path/ckeditor_3.6.2.tar.gz
 cp $path/loncapaconfig.js ckeditor/loncapaconfig.js
Index: doc/loncapafiles/loncapafiles.lpml
diff -u doc/loncapafiles/loncapafiles.lpml:1.819 doc/loncapafiles/loncapafiles.lpml:1.820
--- doc/loncapafiles/loncapafiles.lpml:1.819	Mon Jan  7 01:44:32 2013
+++ doc/loncapafiles/loncapafiles.lpml	Thu Jan 10 05:36:30 2013
@@ -2,7 +2,7 @@
  "http://lpml.sourceforge.net/DTD/lpml.dtd">
 <!-- loncapafiles.lpml -->
 
-<!-- $Id: loncapafiles.lpml,v 1.819 2013/01/07 01:44:32 raeburn Exp $ -->
+<!-- $Id: loncapafiles.lpml,v 1.820 2013/01/10 05:36:30 raeburn Exp $ -->
 
 <!--
 
@@ -4530,7 +4530,7 @@
     Server side png fonts for use by jsMath
   </description>
   <installscript>
-commands /home/httpd/html/adm
+commands
   </installscript>
   <dependencies>
 loncom/html/adm/jsMath/commands;
@@ -4549,7 +4549,7 @@
    unzipping the file, making it look cleaner in the /home/.../adm/ directory
   </description>
   <installscript>
-commands /home/httpd/html/adm/MathJax
+commands
   </installscript>
   <dependencies>
 loncom/html/adm/MathJax/commands;
@@ -4566,7 +4566,7 @@
    HTML5/JavaScript Version of GeoGebra
   </description>
   <installscript>
-commands /home/httpd/html/adm/geogebra/web
+commands
   </installscript>
   <dependencies>
 loncom/html/adm/geogebra/commands;
@@ -4584,7 +4584,7 @@
    installs the loncapa config.js file
   </description>
   <installscript>
-commands /home/httpd/html/
+commands
   </installscript>
   <dependencies>
 loncom/html/adm/ckeditor/commands;




More information about the LON-CAPA-cvs mailing list