Git commit時提示錯誤時 解決辦法


原文: https://www.cnblogs.com/izengbin/p/7122727.html
 
vi 編輯
vim 編輯
a 進入編輯模式
esc 退出編輯模式
shift+:    (看見: ) 代表開始執行下一行命名
w->q 保存退出
q->! 不保存退出
cat->空格->文件名 查看文件 
 
 
* Please tell me who you are. 
Run 
git config –global user.email “you@example.com” 
git config –global user.name “Your Name”
to set your account’s default identity. 
Omit –global to set the identity only in this repository. 
fatal: unable to auto-detect email address
解決辦法: 
打開終端,進入自己的項目下,有個.git目錄 
cd ~/MyPro/.git 
vi config
[core]
      repositoryformatversion = 0
           filemode = true
           bare = false
           logallrefupdates = true
           ignorecase = true
 #添加以下三行:
[user]
     email = yourname@me.com
     name = yourname

to set your account's default identity.Omit --global to set the identity only in this repository.


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM