除了常用的 git push
, git pull
, git status
外漩氨,還有一個命令也是比較比較常用的 git commit
只更新上一次的提交的內(nèi)容
git commit --amend --no-edit
其中
git commit --amend
:表示對最近一次提交進(jìn)行修改
--no-edit:表示不編輯提交消息
只更新上一次的提交的消息
git commit --amend --message="xxxx"
上面 --no-edit
是只更新代碼內(nèi)容,這里的 --message
是 只更新提交的消息