git命令详解 一:常用命令 git add 添加到缓存区 git commit -am " " 添加到本地仓库 git pull 从远程拉去代码到本地仓库 git push 推送代码到远程仓库. 二:图解 git reset --hard