不能推送使用EGit和Bitbucket [英] Can't push using EGit and Bitbucket

查看:191
本文介绍了不能推送使用EGit和Bitbucket的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试使用带有Bitbucket的EGit启动项目,但是我无法将项目推送到服务器中的存储库。



这些步骤我已经遵循了(我会尝试非常具体,所以其他人可以使用它作为教程模式;即使它不适用于我,这可能适用于其他人):



1)我使用本教程在Ubuntu 12.10上安装Git



2)遵循GitHub的本教程




  • 在Eclipse中启动一个新的C ++项目

  • 在窗口>首选项>常规>网络连接> SSH2>密钥管理选项卡,我生成了一个新的RSA密钥,并将其添加到Bitbucket上我的存储库的部署密钥列表。

  • 右键单击eclipse项目:Team> Share project;团队>添加到索引;团队>提交

  • 窗口>显示视图>其他> Git> Git存储库

  • 右键单击Remotes> Create Remote> CheckedConfigure push键入我的项目名称

  • 添加推送URL: ssh://git@bitbucket.org/myuser/myrepository.git ,协议: SSH;端口:空白; user:git;密码:空白

  • 在Ref映射下的高级按钮,并选择主版本。如果此步骤工作,则表示RSA密钥在Bitbucket和EGit中正确配置。否则会显示连接错误。



一切都完成了。但是,当我按推我得到以下错误:

  ssh://git@bitbucket.org/myuser/ myrepository.git:push not allowed 

我已经尝试过所有可能的配置:切换到新的工作空间,更新的Eclipse,创建新的存储库,重新安装Git ...任何想法?

解决方案

好吧,我终于找到了一种使用它的方法。



只是更改身份验证模式。如果使用HTTPS链接,而不是使用SSH链接,一切都可以正常工作。看来,SSH只能在只读模式下工作。





当然,身份验证方法是不同的:您必须键入密码,并且不再需要存储在Bitbucket中的SSH密钥。 / p>

对于那些遇到EGit问题的人,我建议您遵循eugener的方式自动配置EGit。那么你只需要选择HTTPS作为身份验证模式来推送存储的提交。


I've been trying to start a project using EGit with Bitbucket but I can't push the project to the repository in the server.

These are the steps I've followed (I'll try to be very specific so other people can use it as a tutorial mode; even though it's not working for me it might work for others):

1) I installed Git on Ubuntu 12.10 using this tutorial

2) Followed this tutorial for GitHub.

  • Start a new C++ project in Eclipse
  • Under Window > Preferences > General > Network Connection > SSH2 > Key Management tab, I generated a new RSA key and added it to the list of deployment keys of my repository on Bitbucket.
  • Right click on the eclipse project: Team > Share project ; Team > Add to index ; Team > Commit
  • Window > Show View > Other > Git > Git Repositories
  • Right click on Remotes > Create Remote > Checked "Configure push" and typed my project's name
  • Add Push URL: ssh://git@bitbucket.org/myuser/myrepository.git, Protocol: ssh; port: blank; user: git; password: blank
  • Advanced button under Ref mappings and selected the "master" version. If this step works, it means that the RSA key is configured in Bitbucket and EGit properly. Otherwise it will show a connection error.

Everything is done. However, when I press "Push" I get the following error:

ssh://git@bitbucket.org/myuser/myrepository.git: push not permitted

I've tried every configuration possible: switched to a new work space, updated Eclipse, created new repositories, re-installed Git... Any ideas?

解决方案

Alright, I've finally found a way to work with it.

It's just changing the authentication mode. If the HTTPS link is used, instead of using the SSH link, everything works perfectly. It seems that SSH works just in a read-only mode.

Of course the authentication method is different: you have to type the password and the SSH keys stored in Bitbucket are no longer necessary.

For those who are having problems with EGit, I recommend following eugener's way to automatically configure EGit. Then you just have to select HTTPS as authentication mode to push the stored commits.

这篇关于不能推送使用EGit和Bitbucket的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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