Intellij Android Studio打开本地主机页面以登录github

js4nwp54  于 2022-11-16  发布在  Android
关注(0)|答案(4)|浏览(151)

我使用的是android studio版本4.2 beta 3,当我使用GUI推送/获取studio提示登录github时,我已经设置了一个帐户。

奇怪的是,我可以在终端上使用git,但不能在GUI上使用。
我选择了第一个选项,我的浏览器将我导航到一个网站,上面写着在Github中授权,我按下按钮,登录Github,然后我得到了下面的localhost页面,它需要一些未知的凭据。

您对如何解决此问题有什么想法吗?
谢谢

fhg3lkii

fhg3lkii1#

这实际上是一个Android Studio错误。例如,请参见thisthis报告
在相应的IntelliJ IDEA版本中,它工作正常。
作为一种解决方法,请改用令牌登录。

kr98yfug

kr98yfug2#

不幸的是,这个问题仍然存在于android studios的最新版本,但你的令牌工作的变通办法。

byqmnocz

byqmnocz3#

您必须生成一个新的SSH密钥并将其添加到ssh-agent中,您可以找到它there

5us2dqdw

5us2dqdw4#

我的Github账户使用的是我所在组织的单点登录,所以我的做法是进入Github设置-〉SSH和GPG密钥,然后点击按钮在我的SSH密钥上配置SSO。然后点击“授权”为您的组织。
以下是有关如何执行此操作的更多详细信息https://docs.github.com/en/enterprise-cloud@latest/authentication/authenticating-with-saml-single-sign-on/authorizing-an-ssh-key-for-use-with-saml-single-sign-on
当您在 checkout 项目时遇到以下错误时,此操作有效

Clone failed
  ERROR: The `----' organization has enabled or enforced SAML SSO. To access
  this repository, you must use the HTTPS remote with a personal access token
  or SSH with an SSH key and passphrase
  that has been authorized for this organization. Visit
  https://docs.github.com/articles/authenticating-to-a-github-organization-with-saml-single-sign-on/ for more information.
  Could not read from remote repository.
  Please make sure you have the correct access rights
  and the repository exists.

相关问题