Git使用,报错Author identity unknow
git 在刚开始使用时需要设置 user.name, user.email, 不然 git commint的时候会报错Author identity unknown,具体设置步骤:
git config --global user.name 'your name'
git config --global user.email 'your email'
设置完后可以用以下命令查看设置结果;
登录后执行
git config --listy
以下操作在项目文件夹内用PowerSell操作
初始化
git init
git add .
本地提交
git commit -m "add files"
git status
用户名:码云的邮箱
密码:码云的密码
以下是错误的操作解决方案
git报错,git无法提交 - nothing to commit,working tree clean
git rm -r --cached . # 删除本地缓存.cache关键词,如果担心,建议备份"仓库"和"代码"
git config core.autocrlf false # 关闭自动转化末尾换行符(详情看下边)
然后在以此执行