Skip to content

Commit

Permalink
Update libraries to their newest versions
Browse files Browse the repository at this point in the history
Update the Makefile scripts to download the latest library versions, and switch to a custom build of the Smartmenus library
  • Loading branch information
fnesveda committed Oct 26, 2017
1 parent fbbb1e7 commit a401e0c
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 26 deletions.
55 changes: 30 additions & 25 deletions editor/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,83 +8,88 @@ lib : $(LIBRARIES)
ace :
rm -rf tmp
mkdir tmp
git clone https://github.com/ajaxorg/ace-builds.git tmp
rm -rf lib/ace
mkdir -p lib/ace
cp -r tmp/src-min-noconflict lib/ace/src-min-noconflict
cp tmp/LICENSE lib/ace/LICENSE
curl -L https://www.github.com/ajaxorg/ace-builds/tarball/master | tar -xzf - -C tmp
cp -r tmp/ajaxorg-ace-builds-*/src-min-noconflict lib/ace/src-min-noconflict
cp tmp/ajaxorg-*/LICENSE lib/ace/LICENSE
rm -rf tmp

adminer :
rm -rf lib/adminer
mkdir -p lib/adminer
curl -L http://www.adminer.org/latest-en.php -o lib/adminer/adminer.php
curl -L https://raw.githubusercontent.com/vrana/adminer/master/designs/pepa-linha/adminer.css -o lib/adminer/adminer.css
echo "Header unset X-Frame-Options" > lib/adminer/.htaccess

cookie :
rm -rf lib/cookie
mkdir -p lib/cookie
curl -L https://raw.githubusercontent.com/carhartl/jquery-cookie/master/src/jquery.cookie.js -o lib/cookie/jquery.cookie.js

dropzone :
rm -rf tmp
mkdir tmp
rm -rf lib/dropzone
mkdir -p lib/dropzone
curl -L https://github.com/enyo/dropzone/archive/v4.0.1.tar.gz | tar xz -C tmp
cp tmp/dropzone-4.0.1/dist/min/dropzone.min.css lib/dropzone/dropzone.min.css
cp tmp/dropzone-4.0.1/dist/min/dropzone.min.js lib/dropzone/dropzone.min.js
rm -rf tmp
curl -L https://raw.githubusercontent.com/enyo/dropzone/master/dist/min/dropzone.min.js -o lib/dropzone/dropzone.min.js
curl -L https://raw.githubusercontent.com/enyo/dropzone/master/dist/min/dropzone.min.css -o lib/dropzone/dropzone.min.css
curl -L https://raw.githubusercontent.com/enyo/dropzone/master/LICENSE -o lib/dropzone/LICENSE

fileDownload :
rm -rf lib/fileDownload
mkdir -p lib/fileDownload
curl -L https://raw.githubusercontent.com/johnculviner/jquery.fileDownload/master/src/Scripts/jquery.fileDownload.js -o lib/fileDownload/jquery.fileDownload.js
curl -L https://raw.githubusercontent.com/johnculviner/jquery.fileDownload/master/LICENSE -o lib/fileDownload/LICENSE

jquery :
rm -rf lib/jquery
mkdir -p lib/jquery
curl -L http://code.jquery.com/jquery-2.1.4.min.js -o lib/jquery/jquery.min.js
curl -L https://code.jquery.com/jquery-3.2.1.min.js -o lib/jquery/jquery.min.js

jquery-ui :
rm -rf tmp
mkdir tmp
rm -rf lib/jquery-ui
mkdir -p lib/jquery-ui
curl -L --data "version=1.11.4&core=on&widget=on&mouse=on&sortable=on&theme=none&theme-folder-name=no-theme&scope=" http://download.jqueryui.com/download | tar xz -C tmp
cp tmp/jquery-ui-1.11.4.custom/jquery-ui.min.js lib/jquery-ui/jquery-ui.min.js
curl -L http://jqueryui.com/resources/download/jquery-ui-1.12.1.zip | tar xz -C tmp
cp tmp/jquery-ui-*/jquery-ui.min.js lib/jquery-ui/jquery-ui.min.js
rm -rf tmp

jstree :
rm -rf tmp
mkdir tmp
rm -rf lib/jstree
mkdir -p lib/jstree
mkdir -p lib/jstree/themes
curl -L https://github.com/vakata/jstree/archive/3.1.1.zip | tar xz -C tmp
cp tmp/jstree-3.1.1/dist/jstree.min.js lib/jstree/jstree.min.js
cp -r tmp/jstree-3.1.1/dist/themes/default lib/jstree/themes/default
curl -L https://www.github.com/vakata/jstree/archive/3.3.4.zip | tar xz -C tmp
cp tmp/jstree-*/dist/jstree.min.js lib/jstree/jstree.min.js
cp -r tmp/jstree-*/dist/themes/default lib/jstree/themes/default
rm -rf tmp

mousetrap :
rm -rf tmp
mkdir tmp
rm -rf lib/mousetrap
mkdir -p lib/mousetrap
curl -L https://github.com/ccampbell/mousetrap/archive/1.5.3.tar.gz | tar xz -C tmp
cp tmp/mousetrap-1.5.3/mousetrap.min.js lib/mousetrap/mousetrap.min.js
cp tmp/mousetrap-1.5.3/plugins/global-bind/mousetrap-global-bind.min.js lib/mousetrap/mousetrap-global-bind.min.js
curl -L https://www.github.com/ccampbell/mousetrap/archive/1.6.1.tar.gz | tar xz -C tmp
cp tmp/mousetrap-*/mousetrap.min.js lib/mousetrap/mousetrap.min.js
cp tmp/mousetrap-*/plugins/global-bind/mousetrap-global-bind.min.js lib/mousetrap/mousetrap-global-bind.min.js
rm -rf tmp

Services_JSON :
rm -rf tmp
mkdir tmp
rm -rf lib/Services_JSON
mkdir -p lib/Services_JSON
curl -L http://download.pear.php.net/package/Services_JSON-1.0.3.tgz | tar xz -C tmp
cp tmp/Services_JSON-1.0.3/JSON.php lib/Services_JSON/JSON.php
cp tmp/Services_JSON-*/JSON.php lib/Services_JSON/JSON.php
echo "Deny from all" > lib/Services_JSON/.htaccess
rm -rf tmp

smartmenus :
rm -rf tmp
mkdir tmp
rm -rf lib/smartmenus
mkdir -p lib/smartmenus
curl -L -A "Mozilla/4.0" http://www.smartmenus.org/files/?file=smartmenus-jquery/smartmenus-1.0.0-beta1.zip | tar xz -C tmp
cp tmp/smartmenus-1.0.0-beta1/jquery.smartmenus.min.js lib/smartmenus/jquery.smartmenus.min.js
cp tmp/smartmenus-1.0.0-beta1/css/sm-core-css.css lib/smartmenus/sm-core-css.css
rm -rf tmp
curl -L https://raw.githubusercontent.com/fnesveda/smartmenus/disabled-items-no-click/dist/jquery.smartmenus.min.js -o lib/smartmenus/jquery.smartmenus.min.js
curl -L https://raw.githubusercontent.com/fnesveda/smartmenus/disabled-items-no-click/dist/css/sm-core-css.css -o lib/smartmenus/sm-core-css.css

clean :
find lib -type d -mindepth 1 -maxdepth 1 | xargs rm -rf
4 changes: 3 additions & 1 deletion editor/lib/INFO.md
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
* the goal is to have the _Makefile_ download the latest version for all libraries, but some are not making it easy
* jQuery UI
* we only need the _sortable_ utility, so if you are downloading the library manually, you can build a package only with that and its dependencies.
* the makefile now downloads a complete package, though, since the jQuery download API keeps changing
* Smartmenus
* when updating Smartmenus from the original source, reapply [this commit](https://github.com/fnesveda/smartmenus/commit/6228ad82123247c40df3dc0ee4297ededa49dc7f) to fix submenus of disabled items
* when updating Smartmenus from the original source, reapply [this commit](https://github.com/fnesveda/smartmenus/commit/28bec230b154a11a1ea23a1e1ed907d4b82c9e4d) to fix submenus of disabled items
* I will keep a fork with this commit applied until this is fixed in Vadikom's repo (but he doesn't seem to be responding to pull requests)

0 comments on commit a401e0c

Please sign in to comment.