Skip to content

Instantly share code, notes, and snippets.

@binario200
Created August 9, 2018 22:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save binario200/8d187ee09b38772c88729c3d67f089ba to your computer and use it in GitHub Desktop.
Save binario200/8d187ee09b38772c88729c3d67f089ba to your computer and use it in GitHub Desktop.
Install gradle
cd ~/
wget -O ~/gradle-4.7-bin.zip https://services.gradle.org/distributions/gradle-4.7-bin.zip
sudo yum -y install unzip java-1.8.0-openjdk
sudo mkdir /opt/gradle
sudo unzip -d /opt/gradle/ ~/gradle-4.7-bin.zip
sudo vi /etc/profile.d/gradle.sh


Put this text into gradle.sh:

export PATH=$PATH:/opt/gradle/gradle-4.7/bin

Then set permissions on gradle.sh:

sudo chmod 755 /etc/profile.d/gradle.sh

Finally, after logging out of the server and logging back in:

gradle --version

And the commands used to install and run the Gradle Wrapper:

cd ~/
mkdir my-project
cd my-project
gradle wrapper
./gradlew build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment