Why use Gradle Wrapper

Source: Internet
Author: User
Tags wrapper

Each wrapper is bound to a specific version of Gradle, and when the user executes the following command for the first time, wrapper automatically downloads and installs the corresponding version of Gradle, allowing the user to build the project./gradlew [Task] (Unix/linux) Gradlew [Task] (Windows)

The gradler-wrapper.properties configuration download is read.
Distributionbase=gradle_user_home distributionpath=wrapper/dists zipstorebase=gradle_user_home zipStorePath= Wrapper/dists Distributionurl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
Gradlew (Unix) or Gradlew.bat (Windows) Gradle/wrapper/gradle-wrapper.jar (wrapper jar) Gradle/wrapper/gradler-wrapper . Properties (Wrapper properties)

1. Users do not have to download, install, configure Gradle, downloaded gradle distribution is stored in the directory $USER _home/.gradle/wrapper/dists Make sure to use the correct version of Gradle (especially when building a history project) when you build your project

2. Add wrapper to the Gradle project run the wrapper task on the command line to configure the wrapper as follows: $gradle wrapper--gradle-version 3.3 generates related files.
+ 3. Use Gradlew,mac to pay attention to permissions issues./gradlew Clean Build

Reference: https://docs.gradle.org/current/userguide/gradle_wrapper.html

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.