Gradlew wrapper using the download to local gradle.zip file assembly--Go

Source: Internet
Author: User

Original address: http://www.myexception.cn/mobile/1860089.html

Gradlew wrapper use the download to local gradle.zip file installation.
When using Gradlew to build a project, sometimes it is always necessary to download the Gradle-2.2.1-all.zip installation to install. But because Gradle-2.2.1-all.zip is always under the wall. Here's a way to install from the local.

1. Download the Gradle-2.2.1-all.zip package first.
2. Put the downloaded zip package into the {Project.dir}\gradle\wrapper directory (that is, the same directory as gradle-wrapper.properties) to modify {Project.dir}\gradle\wrapper \gradle-wrapper.properties file. As follows:

Reference #wed APR 15:27:10 PDT 2013
Distributionbase=gradle_user_home
Distributionpath=wrapper/dists
Zipstorebase=gradle_user_home
Zipstorepath=wrapper/dists
#distributionUrl =https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
Distributionurl=gradle-2.2.1-all.zip


3. Then run Gradlew build on the line.
4. After installing the Gradle, change the gradle-wrapper.properties back to the right place.

Reference #wed APR 15:27:10 PDT 2013
Distributionbase=gradle_user_home
Distributionpath=wrapper/dists
Zipstorebase=gradle_user_home
Zipstorepath=wrapper/dists
Distributionurl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
#distributionUrl =gradle-2.2.1-all.zip




Another way is to extract the downloaded gradle-2.2.1-all.zip to a directory, then set the path of the Gradle command, and then run the Gradle build on the project directory (note: Gradle instead of Gradlew)

That said, the principle of which everyone should know.

Gradlew wrapper using the download to local gradle.zip file assembly--Go

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.