Git 命令行登录

有时候登录命令行版本的git会出现这个错误

复制代码
1remote: Support for password authentication was removed on August 13, 2021.
2remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.

原因是github不再支持密码验证,需要使用token验证,具体操作如下:

  1. 在github上生成token 网站:github.com/settings/tokens
  2. 下次命令行要求输入密码时,输入token即可

注意:token只会显示一次,所以要保存好,不然就要重新生成了,也可以用密码记录软件保存这个token,在多处使用,因为要一个一个勾选权限也挺麻烦的其实。

相关推荐
春日见1 小时前
如何创建一个PR
运维·开发语言·windows·git·docker·容器
stevenzqzq21 小时前
git 常用操作
大数据·git
Curvatureflight1 天前
Git工作流最佳实践:从混乱到优雅
git
wu~9701 天前
GitHub永不遗忘,使用git push -f来覆盖的提交依旧保留
git·github
Vermouth_001 天前
git clone的时候提示access denied
git
qq_437657271 天前
清楚本地的git并重新登录
git
jiang_changsheng1 天前
工作流agent汇总分析 2
java·人工智能·git·python·机器学习·github·语音识别
顶点多余1 天前
版本控制器-git
linux·git
夔曦1 天前
Git工程日常下拉/上传完整流程(自用)
git
岱宗夫up1 天前
GitHub Desktop如何设置中文?这不是个简单问题
git·github