EGit可以与现有的Eclipse项目和现有的Git仓库配合使用吗? [英] can EGit be used with existing Eclipse projects and existing Git repos?

查看:142
本文介绍了EGit可以与现有的Eclipse项目和现有的Git仓库配合使用吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在使用Eclipse和Git。现在我想用EGit。我的项目有4个包。每个软件包都有一个Git回购。

当我将Git repos导入EGit时,用户文档中有一条指令可导入或创建.project文件。这些.project文件可能与Eclipse相关。我已经有Eclipse项目,所以我不想创建新项目。我仍然可以使用EGit来GUI访问Git仓库,而无需创建新项目或导入项目吗?



项目创建和导入遵循向导中Git仓库的点选择。选择特定软件包的Git仓库似乎很奇怪,然后继续导入一个不是特定软件包的项目。如果我的项目文件不是特定的包,但是我的Git repo是特定于包的,那么我会遇到问题吗?从我拥有4个Git回购站点导入或创建项目4次似乎也很奇怪。编辑:当我尝试导入一个已存在的项目时,找不到任何项目。编辑:当我尝试导入一个已存在的项目时,找不到项目。这可能是由于Git repo文件夹与Eclipse项目不在同一级别。

解决方案

有点像不使用egit导入git项目到工作区,你应该在 .project .classpath 所在的位置创建git repo。



这有助于从现有的导入Git Repositories




I have been using Eclipse and Git. Now I want to use EGit. My project has 4 packages. Each package has a Git repo.

When I import Git repos into EGit, there is an instruction in the user docs to import or create .project files. These .project files might be Eclipse related. I already have Eclipse projects so I don't want to create new projects. Can I still use EGit to have GUI access to Git repos without creating new projects or importing projects?

Project creation and importation follows the point in the wizard where a Git repo is selected. It seems strange to select a package specific Git repo and then proceed to import a project that is not package specific. Will I have a problem if my project file is not package specific, but my Git repo is package specific. It would also seem strange to import or create projects 4 times since I have 4 Git repos. I have been working for many months with Eclipse without EGit using only 1 project.

Edit: When I try to import an existing project, no project is found. This might be due to the fact the Git repo folder is not on the same level as the Eclipse project.

解决方案

A bit like "Importing git project into workspace without using egit", you should have your git repo intialized where the .project and .classpath are.

That facilitates the "Import from existing Git Repositories".

这篇关于EGit可以与现有的Eclipse项目和现有的Git仓库配合使用吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆