installDeps: no need to download jquery at starting time. Remove curl dependency

In installDeps.sh we have a bunch of code (from 2011) that checks for the
existence of jQuery and eventually downloads it, but since 1239ce7f28 (year
2012) jquery is vendorized in /src/static/js/jquery.js.

Also, stop mentioning curl as a dependency in the README.md

Fixes #3494
This commit is contained in:
muxator 2018-10-06 02:25:37 +02:00 committed by muxator
parent 4121add1b8
commit 9aaa02ec70
2 changed files with 4 additions and 37 deletions

View file

@ -56,20 +56,6 @@ if [ -d "../bin" ]; then
cd "../"
fi
#Is gnu-grep (ggrep) installed on SunOS (Solaris)
if [ $(uname) = "SunOS" ]; then
hash ggrep > /dev/null 2>&1 || {
echo "Please install ggrep (pkg install gnu-grep)" >&2
exit 1
}
fi
#Is curl installed?
hash curl > /dev/null 2>&1 || {
echo "Please install curl" >&2
exit 1
}
#Is node installed?
#Not checking io.js, default installation creates a symbolic link to node
hash node > /dev/null 2>&1 || {
@ -120,25 +106,6 @@ echo "Ensure that all dependencies are up to date... If this is the first time
exit 1
}
echo "Ensure jQuery is downloaded and up to date..."
DOWNLOAD_JQUERY="true"
NEEDED_VERSION="1.9.1"
if [ -f "src/static/js/jquery.js" ]; then
if [ $(uname) = "SunOS" ]; then
VERSION=$(head -n 3 src/static/js/jquery.js | ggrep -o "v[0-9]\.[0-9]\(\.[0-9]\)\?")
else
VERSION=$(head -n 3 src/static/js/jquery.js | grep -o "v[0-9]\.[0-9]\(\.[0-9]\)\?")
fi
if [ ${VERSION#v} = $NEEDED_VERSION ]; then
DOWNLOAD_JQUERY="false"
fi
fi
if [ $DOWNLOAD_JQUERY = "true" ]; then
curl -lo src/static/js/jquery.js https://code.jquery.com/jquery-$NEEDED_VERSION.js || exit 1
fi
#Remove all minified data to force node creating it new
echo "Clearing minified cache..."
rm -f var/minified*