File:  [LON-CAPA] / loncom / html / adm / jsme / commands
Revision 1.1: download - view: text, annotated - select for diffs
Wed Aug 20 18:02:03 2014 UTC (10 years ago) by raeburn
Branches: MAIN
CVS tags: HEAD
- Bug 4729 Molecule editor for chemresponse.
  - JSME instead of JME (eliminate dependency on Java).
  - Molecule editor will resize to when window is resized.

currversion=0
jsmedir='/home/httpd/html/adm/jsme'
if [ -e $jsmedir ]
then
  if [ -e "$jsmedir/VERSION" ]
  then
      currversion=`cat $jsmedir/VERSION`
  fi
fi
newversion=`cat VERSION`
comparison=`echo "$newversion > $currversion" | bc`
if [ $comparison -gt 0 ]
then
  if [ -e $jsmedir ]
  then
    rm -rf $jsmedir
  fi
  unzip -q -o -d $jsmedir JSME_2014-06-28.zip
  mv $jsmedir/JSME_2014-06-28/jsme/* $jsmedir/.
  mv $jsmedir/JSME_2014-06-28/license.txt $jsmedir/license.txt
  rm -r $jsmedir/JSME_2014-06-28
  cp VERSION $jsmedir/VERSION
  chown -R www:www $jsmedir
  find $jsmedir -type d -exec chmod u=rwx,go-rwx {} \;
fi

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>