博客使用文档(防止自己忘了)
总体使用流程
先在文件夹里打开cmd
按照这个流程提交文件
1 | git add . |
然后使用
1 | git push |
输入账号和密钥之后就可以了。
本地在线调试
进文件夹然后
1 | hexo server |
就行了
报错处理大合集
输入账号密码的时候出错
1 | remote: Invalid username or token. Password authentication is not supported for Git operations. |
git已经不能直接用密码登录要使用密钥,去github自己仓库设置里面建一个classic的token,必须得是classic的,自用的把权限拉满就行。
git push时出错
1 | fatal: unable to access 'https://github.com/': Failed to connect to 127.0.0.1 port 7890: Connection refused |
解绑一下代理服务器或者开一下加速器
1 | git config --global --unset http.proxy |
1 | remote: Permission to --- denied to --- |
搞忘了看日志没看见怎么解决的,应该是前面那个密钥建错了没权限了
add的时候出问题
1 | warning: LF will be replaced by CRLF in source/album/friends/index.md. |
linux和windows换行的转换问题
1 | git config --global core.autocrlf false |
可以解决
日常会用到的命令
1 | git config --global user.name |
可以看用户名账号
1 | dir /od /b |
windows提取文件名,按照时间排序,dir可以输出全部内容
All articles on this blog are licensed under CC BY-NC-SA 4.0 unless otherwise stated.
Comments
