eclipse 从github导入ADT Eclipse中的android项目
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/17431920/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Import android project in ADT Eclipse from github
提问by exkoria
I'm trying to import an android project from github into ADT Eclipse but it doesn't find any projects in the repository when I clone it. The repo is clearly an android application project (from looking at the source) but no project is found to import. My steps are as follows:
我正在尝试将一个 android 项目从 github 导入 ADT Eclipse,但是当我克隆它时,它在存储库中找不到任何项目。该 repo 显然是一个 android 应用程序项目(从查看源代码)但没有找到要导入的项目。我的步骤如下:
In "Package explorer" right-click and select "Import"
Import project from Git.
Enter uri: https://github.com/moagrius/MapViewDemo
Just import master.
When cloning is done the following dialog shows up:
在“包资源管理器”中右键单击并选择“导入”
从 Git 导入项目。
只需导入大师。
克隆完成后,会出现以下对话框:
- When choosing "Import existing projects" the below dialog shows:
- 选择“导入现有项目”时,将显示以下对话框:
Why are no projects found to import!? How can I import the projects into eclipse?
为什么找不到要导入的项目!?如何将项目导入 eclipse?
Thanks for help!
感谢帮助!
回答by mneubrand
The eclipse project files (.project and .classpath) are not part of the github repository so you can't just import it into Eclipse.
Eclipse 项目文件(.project 和 .classpath)不是 github 存储库的一部分,因此您不能将其导入 Eclipse。
Easiest way to fix that is probably to create a new Android project yourself and then copy the files from the github repo into it.
解决这个问题的最简单方法可能是自己创建一个新的 Android 项目,然后将 github 存储库中的文件复制到其中。
回答by Engr Muhammad Zohaib
Instead of Selecting the "import existing Projects", just Choose 'Android Project from Existing Code'.
而不是选择“导入现有项目”,只需选择“现有代码中的Android项目”。
- For the 'root directory' click on 'browse' and select the place where you imported your project. (that master one and maybe someother)
- 对于“根目录”,单击“浏览”并选择您导入项目的位置。(那个大师,也许还有其他人)
Press Finish
按完成
回答by shihabkv
7 Easy steps to import Github android projects in to ADT
将 Github android 项目导入 ADT 的 7 个简单步骤
create repository in Github .
select the HTTP clone url .
Clone the project in to local system using clone command.
import the project from the cloned path in to adt.
在 Github 中创建存储库。
选择 HTTP 克隆 url 。
使用 clone 命令将项目克隆到本地系统。
将项目从克隆路径导入到 adt。
5.Select the imported project and click right button.
5.选择导入的项目,点击右键。
6.Click Team->share project.
6.点击团队->共享项目。
7.Click Finish.
7. 单击完成。
==========================
==========================
For Commiting the changes
用于提交更改
Select the project and click right button
Click Team and press Commit , write you comments , click push and commit..
选择项目并单击右键
单击 Team 并按 Commit ,写下您的评论,单击 push 并提交..