Application gradle

From campisano.org
Jump to navigation Jump to search

Gradle

Install

shared/opt install schema v1.2

su -
#### as root
# dependencies
apt-get install curl unzip
# binary
DESTINATION="/home/shared/opt/software"                 # Edit when needed
VERSION="6.0"                                           # Edit when needed
URL="https://downloads.gradle-dn.com/distributions/gradle-${VERSION}-bin.zip"
umask 0027
mkdir -p "${DESTINATION}/tmp"
cd "${DESTINATION}/tmp"
curl -C - -kLO "${URL}"
unzip "gradle-${VERSION}-bin.zip"
cd "${DESTINATION}"
chown -R root:users "tmp"
find "tmp" -type d -exec chmod a-s,u+rwx,g+rx,g-w,o-rwx {} \;
find "tmp" -type f -exec chmod a-s,u+rw,g+r,g-w,o-rwx {} \;
mv "tmp/gradle-${VERSION}" "gradle-${VERSION}"
rm -rf tmp gradle
ln -s "gradle-${VERSION}" gradle
exit
  • and setup your user environment (you can put the follow in ~/.profile)
export GRADLE_HOME="${SOFTWARE_PATH}/gradle"
export PATH="${GRADLE_HOME}/bin:${PATH}";