Manually download Gradle for Android Studio projects

Source: Internet
Author: User

In the example downloaded from http://developer.android.com/samples/index.html, the first thing to do when importing Android studio is to download the Gradle for the corresponding version of the project. Gradle is a build tool primarily for Java applications, similar to the well-known ant under Eclipse, but higher than Ant.

Andriod Studio Download the gradle process is slow, and you can see the progress in the terminal of running./STUDIO.SH:

Copy the URL of the terminal, open in the browser, there are more than 38MB. Under Windows available Thunderbolt download, Linux recommended Firefox + downthemall plugin.

Each version of Android studio download Gradle placed under the ~/.gradle/wrapper/dists/directory (under Windows directory C:\Users\ username \.gradle\wrapper\dists). As shown below, Andriod Studio has downloaded the size of the gradle portion of the file, which shows that it has downloaded about 20MB:

[Email protected]7420: ~/.gradle/wrapper/dists/gradle-1.10-bin/6oa4rff9viiqskhgd6uns5v1f8$ lltotal21432DRWXRWXR-X2WY WY4096Sep - xx: -./DRWXRWXR-X3WY WY4096Sep - xx: -.. /-rw-rw-r--1WY WY0Sep - xx: -gradle-1.10-bin.Zip. Lck-rw-rw-r--1WY WY21931207Sep - xx: -gradle-1.10-bin.Zip. part

Cancel the download in Android studio (although there seems to be a bug that can't be canceled, press CTRL + C to exit Android Studio directly in the terminal running studio.sh).

Remove the Gradle-1.10-bin.zip.part and copy the gradle-1.10-bin.zip you downloaded to this directory. Then start Andriod Studio again, automatically read the Gradle and unzip, and then use the extracted Gradle tool to build your import incoming sample project.

Check the download directory for Gradle again, as follows:

[Email protected]7420: ~/.gradle/wrapper/dists/gradle-1.10-bin/6oa4rff9viiqskhgd6uns5v1f8$ lltotal39472DRWXRWXR-X3WY WY4096Sep - xx: -./DRWXRWXR-X3WY WY4096Sep - xx: -.. /DRWXRWXR-X6WY WY4096Sep - xx: -gradle-1.10/-rw-r-----1WY WY40404574Sep - xx:Panax Notoginsenggradle-1.10-bin.Zip-rw-rw-r--1WY WY0Sep - xx: -gradle-1.10-bin.Zip. Lck-rw-rw-r--1WY WY0Sep - xx: -gradle-1.10-bin.Zip. OK

Lck and OK file size is 0, no actual content, play a role in the logo. OK indicates that this version of Gradle has been cleared (there is no such ok file before the download is complete). LCK file does not know what the effect. (guessing is the meaning of lock, mark whether this version of Gradle has project in use.) If not used, this version of Gradle will be deleted when the total Gradle file reaches the cache limit)

Manually download Gradle for Android Studio projects

Related Article

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.