I downloaded an open source project from GitHub a few days ago and found that it was not the same directory structure as Eclipse before. It is the file directory of the Android Studio that I have been using recently. From the above picture, we can see that the word gradle appears many times. The combination of Android Studio + Gradle is very convenient to use, and many third-party open source projects have already migrated to Studio, so let's learn about this combination together. 1. What is gradle Gradle is based on the groovy language and is mainly for Java applications. It is an automated build tool based on DSl (domain specific language) syntax. This is the explanation from Baidu Encyclopedia. From a personal understanding, we can regard it as a tool for building our projects or engineering. So don't think that it can only be used with our Android studio. Gradle can also be used for the previous development tool Eclipse. It's just that the default tool for building projects in Android Studio is Gradle. 2. Import into Android Studio Faced with such an open source code downloaded from the Internet, how do we import it into our development tools? If you want to import it into Eclipse, we need to download and install the gradle and groovy plug-ins ourselves. Here we still choose Android Studio as our development tool 2.1 First we open our android studio If you have a project before, just close the project. Here we choose to import Non-android studio project. Select the open source code we downloaded. Click OK error message This error prompts us that gradle has not been downloaded. At this time, we click the gradle option on the right sidebar of android studio A pop-up window appears as shown below Click the plus sign, a window for selecting a directory will pop up, select the build.gradle in the project directory we want to import A window as shown below appears, click OK. A window as shown below pops up Download the gradle we need, which requires FQ. The download speed is slow. After the download is complete, our project is imported. I am also a beginner in gradle, and I am still learning some of the content. I also hope to communicate with you. |
<<: Create an APP in four months from zero foundation
>>: Why is the image quality on Android not as high as on iOS?
Virtual Reality (VR), a field that is somewhat un...
Although the author is not an expert, he comes fr...
Ideal Auto released its sales results for August,...
The roulette wheel lottery is one of the activity...
Recently, the Ministry of Agriculture and Rural A...
[[143647]] The naughty child Xiao Ming and his mo...
Friends still keep asking about Baidu information...
There are activities on today’s e-commerce platfo...
Today we are going to talk about the delivery of ...
This year, Guangzhou has experienced the longest ...
If you encounter food choking, don't try any ...
The global electric vehicle battery market grew 1...
The 2020 summer advertising war is about to end, ...
Moss-covered trees in Devon, England. © Adam Burt...
After the college entrance examination results ar...