Android studio import open source project

Android studio import open source project

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?

Recommend

18 Practical Marketing Experiences from Advertising Mad Man Ye Maozhong

Are you worried about how to improve your brand a...

How does product operation improve user stickiness?

Products of various categories cover all aspects ...

Analysis of Taobao and Douyin’s live e-commerce competitors

This article focuses on Douyin e-commerce, analyz...

Those cute but ferocious "little" animals

Those cute but ferocious "little" anima...

He weaves a space computing network by the Zhijiang River

“Which is more important, talent or hard work?” &...

What is Taobao Alliance? How to promote Taobao Alliance?

Taobao merchants are no longer unfamiliar with Ta...

Are nano products a waste of money? In fact, nanotechnology is not just "small"

The word “nano” sounds so technological, so putti...

Do “sleep-aiding foods” really help you sleep?

This is the 4373rd article of Da Yi Xiao Hu Sleep...

How come “big fat meat” and “little maggots” grow in vinegar?

Vinegar, as a common condiment, is often used in ...

How do K12 online education products achieve user growth?

This article mainly discusses the response strate...

4 Steps to Reconstruct Growth Hacking Logic

Even the new graduates I teach know the AARRR mod...

When an undersea volcano erupts, why can't seawater extinguish it?

Submarine volcanoes, as the name suggests, are vo...

"The Biography of Zeng Guofan" - Zhang Hongjie Baidu Cloud Download

Biography of Zeng Guofan - Preface by Zhang Hongj...