简体   繁体   English

如何将Gradle添加到Android Studio中的现有项目?

[英]How to add Gradle to an existing project in Android Studio?

I have an existing project in Android Studio that I originally imported from Eclipse. 我最初从Eclipse导入了Android Studio中的现有项目。

I haven't been using any specific build system to build my project other than the one provided by default with the Android Studio IDE (though the project was originally created with Eclipse. 除了默认使用Android Studio IDE提供的系统之外,我没有使用任何特定的构建系统来构建我的项目(尽管该项目最初是使用Eclipse创建的。

I haven't been able to find a good tutorial of the steps. 我还没有找到一个很好的步骤教程。 What's the recommended approach to add Gradle to this project? 建议将Gradle添加到此项目的方法是什么?

Any help would be greatly appreciated. 任何帮助将不胜感激。

Thanks! 谢谢!

I would recommend creating a new project in android studio as the folder structure used by gradle is different than the one used by eclipse. 我建议在android studio中创建一个新项目,因为gradle使用的文件夹结构与eclipse使用的文件夹结构不同。 Then copy the files into their matching folder. 然后将文件复制到其匹配的文件夹中。

Here is a detailed description about the folder structure: https://developer.android.com/tools/projects/index.html 这是有关文件夹结构的详细说明: https : //developer.android.com/tools/projects/index.html

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将libgdx添加到现有的android studio项目中? - How to add libgdx to an existing android studio project? 如何将 gradle java 项目作为依赖项添加到 Android Studio - How to add a gradle java project as dependency to Android Studio 如何将Google Core API依赖项添加到Android Studio Gradle项目? - How to add the Google Core API dependency to an Android Studio Gradle project? 如何将jcompilo作为gradle依赖项添加到android studio项目 - How to add jcompilo as a gradle dependency to android studio project 如何将 Gradle 添加到现有的 JavaFX 项目(IntelliJ) - How to add Gradle to existing JavaFX Project (IntelliJ) 如何将JAR文件添加到现有gradle项目? - How to add a JAR file to an existing gradle project? Android Studio&Gradle:将外部Java类添加到Android主项目 - Android Studio & Gradle: Add outside java classes to Android main project 如何将最初用IDEA或Eclipse编码的android项目转换为Android Studio并添加Gradle? - How can I convert an android project originally coded in IDEA or Eclipse to Android Studio and add Gradle? 如何将 StompProtocolAndroid 添加到 Android Studio gradle? - How to add StompProtocolAndroid to Android Studio gradle? 如何将现有的java项目导入android studio? - How to import existing java project into android studio?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM