遇到问题:使用指令git push
报错,如下:
remote: Support for password authentication was removed on August 13, 2021.
remote: 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.
fatal: Authentication failed for 'https://github.com/wanghuiwiki/shop.git/'
解决办法:
fatal提示参考:https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning
github docs 文档中描述说当Git提示你输入密码时,请输入你的personal access token
➥创建 personal access token
然后再次尝试git push指令;根据弹框输入用户名和刚保存的token;举例:我这里是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
如果看到如下效果(没有fail错误),则表明提交成功.
[验证]此时可以观察浏览器,刷新线上仓库的地址;