【问题标题】:How to make Tools->Git->Push work in Qt Creator如何使 Tools->Git->Push 在 Qt Creator 中工作
【发布时间】:2012-11-10 15:37:54
【问题描述】:

当我尝试 Tools->Git->Push in Qt Creator 时,我得到了

fatal: remote error: Invalid username/password.
You may need to use your generated googlecode.com password; see https://code.google.com/hosting/settings
The command 'C:\Program Files\Git\cmd\git.exe' terminated with exit code 128.

我有远程存储库的密码,但在 Qt Creator 的设置中找不到输入密码的位置。

【问题讨论】:

    标签: windows git qt-creator


    【解决方案1】:

    我有同样的问题,唯一的解决方案是在终端中运行它。我没有找到更好的方法。如果你找到更好的方法,请告诉我。

    【讨论】:

      【解决方案2】:

      我在这里找到了解决问题的解决方案:

      https://stackoverflow.com/a/70101716/7511257

      这对我来说很容易:

      git push --set-upstream origin master

      【讨论】:

        【解决方案3】:

        您可以使用凭证助手告诉 Git 每次与 GitHub 对话时记住您的 GitHub 用户名和密码。

        您最初需要从 cmd 行进行设置,但随后您的密码将被缓存,并且 Qt Creator -> 远程存储库 -> 推送将按预期工作。

        1. 从终端设置 Windows 凭据助手:

          git config --global credential.helper wincred

        2. 执行推送并在提示时输入您的密码:

          git push

        您的密码现在被缓存以供将来所有推送操作使用,因此从 Qt Creator 推送也可以工作。

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          相关资源
          最近更新 更多