【问题标题】:Creating a new repository using Github is returning an error使用 Github 创建新存储库返回错误
【发布时间】:2019-04-23 02:47:34
【问题描述】:

我是在 GitHub 中创建项目的新手(自动化新手)我已经遵循了一些步骤,并且已经进入了我输入的阶段

  • $ git push -u origin master

当我添加这个时,我得到以下错误返回

 $ git push -u origin master
    fatal: HttpRequestException encountered.

发送请求时出错。

  Unhandled Exception: System.ObjectDisposedException: Cannot access a closed     file.
   at System.IO.__Error.FileNotOpen()
   at System.IO.FileStream.Flush(Boolean flushToDisk)
   at System.IO.StreamWriter.Flush(Boolean flushStream, Boolean flushEncoder)
   at Microsoft.Alm.Git.Trace.Microsoft.Alm.Git.ITrace.Flush()
   at Microsoft.Alm.Cli.Program.Die(String message)
   at Microsoft.Alm.Cli.Program.Die(Exception exception)
   at Microsoft.Alm.Cli.Program.Main(String[] args)
    Username for 'https://github.com': awa1ker23
    remote: Invalid username or password.
    fatal: Authentication failed          for 'https://github.com/awa1ker23/DefaultWebFrameWork.git/'

我已经添加了我的用户名和密码,但它说密码验证失败。但是,它绝对是正确的用户名和密码。

我想知道我收到这条消息是不是因为我在 Eclipse 中更改了项目的名称?

【问题讨论】:

    标签: java github automation repository git-bash


    【解决方案1】:

    更新到最新版本的 git 应该可以解决问题。 Download git client

    【讨论】:

    • 这不起作用,我仍然遇到同样的错误。
    • 尝试改用令牌。您可以在以下 url 中查看有关如何生成令牌的指南。 link
    • 我也在下面link看到了类似的问题
    猜你喜欢
    • 2012-04-01
    • 2017-08-09
    • 2021-08-07
    • 2019-11-09
    • 1970-01-01
    • 1970-01-01
    • 2018-01-29
    • 2020-07-12
    • 1970-01-01
    相关资源
    最近更新 更多