关于github:github启用-personal-access-token后历史项目如何进行认证变更

2次阅读

共计 492 个字符,预计需要花费 2 分钟才能阅读完成。

依照 github 的官网说法,github 于 2020 年 11 月 13 日起逐渐的推广应用 token 认证代替原来的用户名明码认证,该项工作于 2021 年年中左右推广结束。所以一些历史上咱们应用用户名 + 明码拉取的 github 仓库在进行 git pull \ push \ fetch 等操作时,会报如下谬误:

remote: Password authentication is temporarily disabled as part of a brownout. Please use a personal access token instead.
remote: Please see https://github.blog/2020-07-3… for more information.

解决办法如下:
一、删除零碎记往的明码
不同的零碎删除零碎记的明码不同,macos 参考官网帮忙文档进行删除即可。

二、配置 git 的全局的认证帮忙器为空

 git config --local credential.helper ""

此时,在执行一些 git 操作时,则会提醒咱们输出用户名明码,此时明码输出在 github 中的设置的 token 即可。设置 token 的办法可参考官网文档。

正文完
 0