[LON-CAPA-cvs] cvs: loncom /html/adm/MathJax VERSION commands

raeburn raeburn at source.lon-capa.org
Wed May 23 21:35:55 EDT 2012


raeburn		Thu May 24 01:35:55 2012 EDT

  Added files:                 
    /loncom/html/adm/MathJax	VERSION 

  Modified files:              
    /loncom/html/adm/MathJax	commands 
  Log:
  Include MathJax version information.
    - Only install when running ./UPDATE if MathJax is absent, or if a newer
      version is included in LON-CAPA tarball.
  
  
Index: loncom/html/adm/MathJax/commands
diff -u loncom/html/adm/MathJax/commands:1.1 loncom/html/adm/MathJax/commands:1.2
--- loncom/html/adm/MathJax/commands:1.1	Tue Dec  6 16:23:30 2011
+++ loncom/html/adm/MathJax/commands	Thu May 24 01:35:55 2012
@@ -1,6 +1,17 @@
-rm -rf $1/
-unzip -q -o -d $1 mathjax-MathJax-v1.1a-0-g1697387.zip
-mv $1/mathjax-MathJax-f5cd294/* $1/.
-rm -r $1/mathjax-MathJax-f5cd294
-chown -R www:www $1
-find $1 -type d -exec chmod u=rwx,go-rwx {} \;
+currversion=0.0
+if [ -e "$1/VERSION" ]
+then
+  currversion=`cat $1/VERSION`
+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 {} \;
+fi




More information about the LON-CAPA-cvs mailing list