remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/jifanxi/helloworld002.git/'
这条信息表明,您在使用 Git 进行远程操作时,遇到了由于 GitHub 在 2021 年 8 月 13 日取消了密码认证支持而引发的问题。为了继续使用 Git 进行远程操作,您需要采用其他认证方法,例如使用个人访问令牌(Personal Access Token, PAT)或 SSH 密钥。
以下是如何使用个人访问令牌替代密码进行认证的步骤:
生成个人访问令牌
-
登录 GitHub:
打开 GitHub 网站并登录到您的账户。 -
进入设置:
点击右上角的头像,选择“Settings”。 -
进入开发者设置:
在左侧菜单中,选择“Developer settings”。 -
生成新令牌:
在左侧菜单中,选择“Personal acc