如何从VSCode删除GitHub密码? [英] How to remove GitHub password from VSCode?

查看:926
本文介绍了如何从VSCode删除GitHub密码?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已使用VSCode克隆了我的GitHub存储库之一,并进行了一些提交。当我完成第一次提交时,VSCode要求我提供我的GitHub密码。

I have cloned one of my GitHub repositories with VSCode and I have made some commits. VSCode has asked me for my GitHub password when I have done the first commit.

我已经重启了计算机,现在我可以像以前一样进行提交了,但是VSCode并没有要求输入我的密码。似乎密码已存储。
但是这台计算机不是我的计算机,我不希望其他人可以使用我的帐户。

I have rebooted the computer and now I can make commits as before, but VSCode does not ask for my password. It seems that the password has been stored. But this computer is not my computer and I do not want that somebody else could use my account.

如何使VSCode忘记我的GitHub密码?

How can I make VSCode forget my GitHub password?

我尝试了git命令:

git config --global --unset-all user.email

但是VSCode仍然让我无需询问即可提交。

But VSCode still lets me commit without asking.

推荐答案

检查您的 git config credential.helper


  • 如果它是经理,则需要打开Windows凭据管理器并在其中删除凭据。

    参见此答案以获取说明。

  • if it is manager, you would need to open your Windows Credential Manager and remove your credentials there.
    See this answer for illustration.

git credential-manager reject https://github.com


  • 如果它是 osxkeychain ,请参阅 已更新从OSX钥匙串中获取凭据

    git credential-osxkeychain erase https://github.com
    


  • 提醒,这些凭据(用户名/密码)没有什么可修改的使用您的git config user.name / user.email

    Reminder, those credentials (username/password) have nothing to do with your git config user.name/user.email.

    这篇关于如何从VSCode删除GitHub密码?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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